General :: Determine The Size Of Each File In A Folder?
Nov 30, 2010i have a folder with 10 files and i would like to determine the size of each file. i was trying the command
Code:
du -sh foldername
but i receive the total size .
i have a folder with 10 files and i would like to determine the size of each file. i was trying the command
Code:
du -sh foldername
but i receive the total size .
Multiple dirs full of mp3s All strictly encoded with exactly the same parameters (CBR 128kbps, Joint-Stereo, etc) Is it possible to determine the total playing time (to within ~98% accuracy) by some formula based on the total file size? I say ~98% accurate since ID3 tags do consume a small amount of space.
View 3 Replies View RelatedI have the following which works but think there must be a easier one-liner way of doing this which involves not writing to a file but have failed to find something that works This is what I have:
Code:
du -m $i > filesize.txt
FILESIZE=$`cat "filesize.txt" | cut -f1
rm filesize.txt
I then use the FILESIZE to compare to a number.
When I try to burn some .flv files onto a DVD iso using K3B, it gives me the message: "Could not determine size of resulting image file"
View 1 Replies View RelatedI am using SSH to connect to a CentOS server and I want to get the file in mb of some files and folders, how can I do it?
View 2 Replies View RelatedI want to generate a temporary random list from a directory of files and then determine the size of an arbitrary block of files from this list (say 1-25 or 26-50) and add their names to a file along with some other info for each name. I can generate a random list with file sizes like this: ls -l | sort -R | cut -d " " -f 6 but i'm not sure how to add up the sizes of just a certain block of these files and at the same time save the file names.
View 2 Replies View RelatedIn Linux bash shell, for a given directory, how can I list:The create date for that directory The number of files in that directory The number of subdirectories in that directory.
View 3 Replies View Relatedi want to change the mtu size of my ethernet controller. I have done successfully set the mtu size 9000 for broadcom net xtreme PCI: 66 Mhz 64 bit 1 gigabit card. (fibre)
Part model no: BCM95703A31
[root@lux08 ~]# ethtool eth0Settings for eth0:
Supported ports: [ FIBRE ]
Supported link modes: 1000baseT/Half 1000baseT/Full
Supports auto-negotiation: Yes
[Code]....
how to change the mtu size for this NIC?
As I have a opt/sybase folder in Linxs I want to increase the size of this folder how can I increase it? For example the size we mention at the time of installation Sybase is 2gb now I want to increase by 4gb how can I increase it.
View 2 Replies View RelatedI want to know is there a command to find size of a folder.
View 4 Replies View RelatedIs there a way to determine the IO size that is being used for reads and writes to an attached storage device? I am trying to pattern the IO sequences to storage. I have seen mentions to max_sectors_kb but the notes indicated that changing this value did not change the IO size to the storage.
View 1 Replies View RelatedI'd like to determine what process has ownership of a lock-file. The lock-files are simply a file with a specific name that has been created.So, how can I determine what process has a particular file open in Linux? Preferably a one-liner type or a particular Linux tool solution would be optimal.
View 3 Replies View RelatedI am writing, well actually enhancing, a script to do a daily backup of important data on my PC to a second hard drive.I wish to tar my home directory to a single file - and will probably use gzip as well.So I decided to work out the correct tar syntax in a terminal first - here is what happened.I opened a terminal window.I cd to a directory not part of my home directory.I issued the command..Quote: tar -cvf mytar.tar /home/ken tar processed a bunch of files, the last being .netrc.I examined the tar file and it contains .netrc.The contents of .netrc are correct.I scrolled back through the list of files in the terminal window and do not see any error messages.I guess the question is... how do I determine what file tripped up the tar process?
View 8 Replies View RelatedI know these folders each have >80gb of files. Yet, they only show 4.0K in ls -lah? How can I have ls show size including the contents?
[root@aapsan01 aapxen01]# ls -lah
total 48K
drwxrwxrwx 6 root root 4.0K Sep 29 03:45 .
drwxrwxrwx 15 root root 4.0K Sep 27 09:15 ..
[Code]....
I'm installing things in a new Red Hat server and saw that the /var folder is full (100%). I need this folder to have more space or another kind of solution because this server is going to be used as a print server.
View 7 Replies View Relatedhow do I increase the size of my home folder in OpenSuse11.3
View 12 Replies View RelatedIn Linux, I'd like to know how to find the file(s) if any which as using a particular sector on the hard drive (ext2/3). There is a similar question here regarding Windows, however I need a Linux command line solution (this is a headless system).
View 1 Replies View RelatedIs there any way to tell which file or directory this is referencing in particular?
View 8 Replies View Relatedif there's a tab-delimited file under /usr/desktop, how can I determine the number of rows and columns of the file in shell?And, if told the the 3rd column of the file contains only numerical values and all values in the 5th column are unique, how can I verify these in shell?
View 13 Replies View RelatedI have written a script.
#/bin/bash
a=`du -sh /root/samplefolder | cut -f1`
echo $a > testfile
[code]....
The aim of this script is, when the folder reaches 20M then attributes will be set to that particular folder so that no newfiles and folders cannot be created or copied to that samplefolder. whenever i copy a file morethan 20M to that folder its getting copied fully and then the attributes were applied. But i dont want this to happen, when the folder reaches its maximum current write operation to that folder should be stopped automatically with a error.
how to create a script when my mailqueue (mqueue) folder size reaches 1GB and sent email alert to my email id.
Once mqueue folder size reaches the sent alert by mail. Because everytime my mqueue folder size increasing.
I had only Arch on an HDD.sda2 was "/".Now it's with Windows XP and sda2 is not a root any more but a container partition wich has sda{5,6,7} in it. I configured the dual boot and it works. It finds Arch and boots it, but not completely. Stops after some time and says: unable to determine the file system type of /dev/sda2. FSTAB is configured, sda{5,6,7} are on their places. So I can't boot Arch. XP boots correctly. What do I do with this error?Also it says: try adding rootfstype=your_filesystem_type to kernel command line.
View 4 Replies View RelatedAre there software that can split big file size into small file size in Linux?
View 1 Replies View RelatedI was just testing specifying limit on file size to a user and have added the following to /etc/security/limits.conf bob soft fsize 100 This basically should have said not to allow bob to create anyfile greater than 100Kb in size.
But the interesting thing is, if bob already has any file which is greater than 100Kb in size, it even doesn't allow to log him into the system both from console and SSH. Also nothing is logged in logs.. How do I configure it so that, bob can login to the system even though he has any file greater than 100Kb (but doesn't allow him to create file which are greater than 100Kb) ??
I have a display problem since updating to Slackware 13.37. Everything was fine on Slackware 13.1, but when I switched to 13.37 some piece of software came up with the wrong monitor size. I have a 1600x900 LCD monitor but the X screen came up as 1024x768 with blackness on either side of it. Under Slackware 13.1 the X screen came up as 1600x900 as it should without any prompting from me; I didn't even have an Xorg.conf file. I tried using the Xorg.conf file which was needed and work for older Slackwares, eg 12.*, but it didn't work. (Saying it didn't work is a gross understatement! That old Xorg.conf completely screwed up mouse, keyboard, and monitor; the screen was flashing and nothing worked. The only way to get control back was to SSH into the machine from my laptop and reboot. Killing the X server via that SSH console did NOT the flashing or get me back to my console login; only reboot worked.)
I find I can get the screen to be the right size manually by going through KDE's "System Settings" --> "Display and Monitor" --> "Size & Orientation", then disabling "LVDS1" and setting VGA1 to 1600x900. The size of my odd-sized monitor is being correctly detected for the "Auto" choice. Upon reboot LVDS1 stays disabled but VGA1 reverts to 1024x768 so I have to do this each time.I've done some search of the on-line literature regarding the error messages I am seeing in the boot log.
People are suggesting changing all kinds of things to alleviate the side effects of the "conflicting" error message above, even modifying GRUB parameters (which won't work for me since I use LILO).So, I have a manual work around which I must do each time I log in. Does someone know how I can get X or KDE to force 1600x900 upon start (while Linux/X/whoever find and fix the problem) or does someone know of a real fix?
is lvresize with --resizefs options re-size the Logical Volume and then re-size the file system? i mean we don't need to use resize2fs?I looked at man pages but it doesn't explain this option.
View 3 Replies View RelatedHow can we find the maximum size of the inode table and what decides it, and how the maximum size of volume of file system is decided ?
View 4 Replies View RelatedI am writting a script to allow uploading of certain files. I want to limit the files by their filename and mime type, and by making sure the two match up.The first thing I need to do is make sure I've got all the mime types I need added. I have never done this before, but I understand that 'file' (which is what PHP's mime-type finding is based off of) uses magic databases that tell at which point in the file should have signatures of the filetype.
My trouble started when I was unable to determine the filetype of any of my video files. Currently, I have some .MOV and .MP4 files that I am using to test.
How can I check and set who can view or open a given folder or file?
View 1 Replies View RelatedI have a large number of folders that each contain quite a few files of varying sizes (from a few bytes to 400kb or so), mostly smaller ones. I need to get the actual (not the disk usage) size of these folders. Is there any way to do this with a command like 'du'?
View 4 Replies View Related