LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices

Reply
 
Search this Thread
Old 10-27-2010, 05:14 PM   #1
aikempshall
Member
 
Registered: Nov 2003
Location: Bristol, Britain
Distribution: Slackware
Posts: 379

Rep: Reputation: 37
umount slow and df reports wrong partition


Using slackware 13.1 and linux 2.6.33.4

For a long time I've used rsync to backup my documents directory to a usb stick without any issues. Since upgrading the umount command takes a very long time to umount the usb drive. This is what I do -


Code:
mount /dev/sdc1
rsync -av --delete --modify-window=4 -L /home/alex/Documents/ /mnt/backup/alex/Documents/ 
umount /dev/sdc1
As I've said the umount takes a very long time to do it's business. Bizarely the df command is showing something really strange -


before the mount

Code:
Filesystem            Size  Used Avail Use% Mounted on
/dev/root              37G   19G   17G  54% /
/dev/sdb2             101G   64G   33G  67% /home
tmpfs                1005M     0 1005M   0% /dev/shm

after the mount upto and including immediately before the umount. Note the addition of /dev/sdc1

Code:
Filesystem            Size  Used Avail Use% Mounted on
/dev/root              37G   19G   17G  54% /
/dev/sdb2             101G   64G   33G  67% /home
tmpfs                1005M     0 1005M   0% /dev/shm
/dev/sdc1             3.8G  2.9G  935M  76% /mnt/backup

Then immediately from when the umount is called to the time that the drive is unmounted. Note how the stats for /dev/sdc1 have changed -

Code:
Filesystem            Size  Used Avail Use% Mounted on
/dev/root              37G   19G   17G  54% /
/dev/sdb2             101G   64G   33G  67% /home
tmpfs                1005M     0 1005M   0% /dev/shm
/dev/sdc1              37G   19G   17G  54% /mnt/backup
Upto when the umount was called df reported the partition as -

/dev/sdc1 3.8G 2.9G 935M 76% /mnt/backup

whereas when it's being unmounted df reports

/dev/sdc1 37G 19G 17G 54% /mnt/backup

the Size, Used, Avail and Use% which df is reporting during the umount just so happens to be exactly the same numbers as df reports for /dev/root. So something's got confused somewhere.

Now if the system, on the umount, now sees a drive of 37G whereas it should see a drive of only 3.8G this could explain why it takes a long time to umount. However, there is minimal disk activity on /dev/root and a lot of activity on /dev/sdc1. Eventually it is the correct partition that is unmounted.


As this problem seems to be so bizarre and I've not managed to find a similar posting elsewhere I might elect to do a fresh install and see what happens.

Before I do that has anyone got any suggestions.
 
Old 10-28-2010, 10:38 AM   #2
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Hanover, Germany
Distribution: Main: Gentoo Others: What fits the task
Posts: 15,582
Blog Entries: 2

Rep: Reputation: 4037Reputation: 4037Reputation: 4037Reputation: 4037Reputation: 4037Reputation: 4037Reputation: 4037Reputation: 4037Reputation: 4037Reputation: 4037Reputation: 4037
I also recognized a change in my USB-device behaviour. If I copy a huge amount of data to a USB-stick, and the data is not to huge to go to the cache first, then the data is copied into the cache and the copy command returns. The real copy process is backgrounded to another thread. So if you immediatly unmount after copying the mount command waits until the data is copied.
I think this is the same thing that you have recognized on your system.

Please anybody, correct me if I am wrong here.
 
  


Reply

Tags
df, rsync, umount


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
DF reports wrong disk size pobman Linux - Newbie 6 08-29-2012 09:58 AM
df reports wrong disk space ioanv Linux - General 4 08-24-2007 08:46 AM
df reports wrong results jjrowan Linux - Software 4 05-11-2006 10:01 AM
df reports wrong disk usage Mathieu_G Linux - General 4 04-13-2005 02:44 PM
df reports wrong result for Win partition sharathkv1 Fedora 2 09-03-2004 06:24 AM


All times are GMT -5. The time now is 04:55 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration