SEARCH

Enter your search query in the box above ^, or use the forum search tool.

You are not logged in.

#1 2012-09-02 17:29:38

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

[Solved] strange /root entry in 'df -h'

Answer:

Awebb wrote:

The phenomenon seems to be gone in systemd (new init coming to Linux-land).

and I'm out the door late as usual!!!!!  Back later!

======================
Does anyone have any idea why df -h reports /root to the system I'm logged into like this:

/dev/disk/by-uuid/44ef4aec-4d2f-464f-9443-c2197895fe29  9.3G  4.6G  4.3G  52% /

or

/dev/disk/by-uuid/62874c9e-7f1b-4204-a273-f0699e31c62c  9.3G  6.6G  2.3G  75% /

More information:
Logged into /dev/sda1: df -h

Filesystem                                              Size  Used Avail Use% Mounted on
rootfs                                                  9.3G  4.6G  4.3G  52% /
udev                                                     10M     0   10M   0% /dev
tmpfs                                                   599M  384K  599M   1% /run
/dev/disk/by-uuid/44ef4aec-4d2f-464f-9443-c2197895fe29  9.3G  4.6G  4.3G  52% /
tmpfs                                                   5.0M     0  5.0M   0% /run/lock
tmpfs                                                   2.0G     0  2.0G   0% /run/shm
/dev/sda2                                                14G  3.2G   11G  24% /home
/dev/sda5                                               117G   42G   70G  38% /media/5
/dev/sda8                                                67G  1.1G   62G   2% /media/8

fstab:

# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
# / was on /dev/sda1 during installation
UUID=44ef4aec-4d2f-464f-9443-c2197895fe29 /               ext4    errors=remount-ro 0       1
# /home was on /dev/sda2 during installation
UUID=e629141f-6e14-49c8-b5b3-4a60956fe00f /home           ext4    defaults        0       2
# /media/5 was on /dev/sda5 during installation
UUID=6fc763f2-2587-4572-bc51-39726ab34fc6 /media/5        ext4    defaults        0       2
# /media/8 was on /dev/sda8 during installation
UUID=a08073a4-f928-482b-9b34-ebe0b0b74ba6 /media/8        ext4    defaults        0       2
# swap was on /dev/sda3 during installation
UUID=054fc6c7-f89d-4112-a72c-b63f4b1ad12e none            swap    sw              0       0
/dev/scd0       /media/cdrom0   udf,iso9660 user,noauto     0       0

Logged into /dev/sda6:  df -h

Filesystem                                              Size  Used Avail Use% Mounted on
rootfs                                                  9.3G  6.6G  2.3G  75% /
udev                                                     10M     0   10M   0% /dev
tmpfs                                                   598M  428K  598M   1% /run
/dev/disk/by-uuid/62874c9e-7f1b-4204-a273-f0699e31c62c  9.3G  6.6G  2.3G  75% /
tmpfs                                                   5.0M     0  5.0M   0% /run/lock
tmpfs                                                   2.0G     0  2.0G   0% /run/shm
/dev/sda5                                               117G   42G   70G  38% /media/5
/dev/sda7                                                14G  4.2G  9.2G  32% /home
/dev/sda8                                                67G  1.1G   62G   2% /media/8

and fstab:

# /etc/fstab: static file system information.
#
# Use 'blkid' to print the universally unique identifier for a
# device; this may be used with UUID= as a more robust way to name devices
# that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
# / was on /dev/sda6 during installation
UUID=62874c9e-7f1b-4204-a273-f0699e31c62c /               ext4    errors=remount-ro 0       1
# /home was on /dev/sda7 during installation
UUID=fff46aa2-f36b-4e78-8135-736f1754a2a3 /home           ext4    defaults        0       2
# /media/5 was on /dev/sda5 during installation
UUID=6fc763f2-2587-4572-bc51-39726ab34fc6 /media/5        ext4    defaults        0       2
# /media/8 was on /dev/sda8 during installation
UUID=a08073a4-f928-482b-9b34-ebe0b0b74ba6 /media/8        ext4    defaults        0       2
# swap was on /dev/sda3 during installation
UUID=054fc6c7-f89d-4112-a72c-b63f4b1ad12e none            swap    sw              0       0
/dev/scd0       /media/cdrom0   udf,iso9660 user,noauto     0       0

How do I get it to report:

/dev/sda1/          9.3G  4.6G  4.3G  52% /

or

/dev/sda6/          9.3G  6.6G  2.3G  75% /

Thanks.

Last edited by Sector11 (2012-09-02 19:38:03)


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

Be excellent to each other!

#2 2012-09-02 18:02:40

VastOne
#! Ranger
From: V-Ger
Registered: 2011-04-26
Posts: 10,165
Website

Re: [Solved] strange /root entry in 'df -h'

I think di may be the answer ... it is installable

sudo apt-get install di

and gives this output

vastone@vastone:~$ di
Filesystem         Mount               Size     Used    Avail %Used  fs Type 
rootfs             /                  78.6G    16.8G    57.7G   26%  rootfs  
/dev/disk/by-uuid/ /                  78.6G    16.8G    57.7G   26%  ext4    
udev               /dev               10.0M     0.0M    10.0M    0%  devtmpfs
/dev/sda3          /media/Boot_Gru   100.6G     5.9G    89.6G   11%  ext4    
/dev/sda5          /media/sda5        77.9G    29.4G    44.5G   43%  ext4    
/dev/sda6          /media/sda6       153.5G     2.9G   142.8G    7%  ext4    
/dev/sda7          /media/sda7       148.5G     4.3G   136.6G    8%  ext4    
/dev/sda2          /media/vsido_sd   109.0G     4.9G    98.6G   10%  ext4    
tmpfs              /run              395.9M     0.4M   395.5M    0%  tmpfs   
tmpfs              /run/lock           5.0M     0.0M     5.0M    0%  tmpfs   
tmpfs              /run/shm          791.7M     0.1M   791.7M    0%  tmpfs   

di has parameters to use (man di for them)

If you want just the info for whatever you are logged into, you could then grep for just it...

This shows the current root

di | grep rootfs

rootfs             /                  78.6G    16.8G    57.7G   27%  rootfs  

This shows another sda entry

di | grep sda3

/dev/sda3          /media/Boot_Gru   100.6G     5.9G    89.6G   11%  ext4    

I am not sure if this is the answer you were looking for?


VSIDO | Words That Build Or Destroy

I dev VSIDO

Offline

#3 2012-09-02 18:09:56

Awebb
The Singularity
Registered: 2009-07-23
Posts: 2,812

Re: [Solved] strange /root entry in 'df -h'

I know why. Your bootloader (grub?) mounts the root filesystem by UUID, not by device node. Upon invoking df, the initial kernel entry is read (don't nail me down on the words I use in this case), so the UUID is printed. It is normal and was introduced by a kernel update, something pre-3.0. If you really want to get rid of this... erm... I wouldn't recommend that... erm... switch from UUID in the grub menu.lst to device nodes.

Yes, please post your /boot/grub/menu.lst :-)

EDIT:

It seems like the /etc/mtab is generated by looking up /proc/mounts, which is generated when the filesystem is mounted (here clearly by grub and never again, since it is the / of all evil). Post your /proc/mounts and your /etc/mtab (or compare them to understand, what I said). The phenomenon seems to be gone in systemd (new init coming to Linux-land) as well as in upstart (Ubuntu init).

Last edited by Awebb (2012-09-02 18:15:12)


I'm so meta, even this acronym

Offline

#4 2012-09-02 18:27:11

xaos52
The Good Doctor
From: Planet of the @s
Registered: 2011-06-24
Posts: 4,602

Re: [Solved] strange /root entry in 'df -h'

I think it is controlled by the entry GRUB_DISABLE_LINUX_UUID=true in /etc/default/grub
Try uncommenting it and then run

sudo update-grub
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true

IIRC it is discouraged, using UUID is recommended.

I have not tested this myself. Thread carefully.

Offline

#5 2012-09-02 19:24:44

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: [Solved] strange /root entry in 'df -h'

Personally I really don't care that it's there, but it's new, and annoying as it means that df -h no longer runs in a normal size terminal:
adxsKbm0.jpg
... so I have to stretch it all the time just to read it.

Notice too how there are two entries for /root:

rootfs                                                  9.3G  6.6G  2.3G  75% /
/dev/disk/by-uuid/62874c9e-7f1b-4204-a273-f0699e31c62c  9.3G  6.6G  2.3G  75% /

I noticed this and then mrpeachy's new LUA script picks that up as the mount point, not the rootfs one which would have been better:
aciYr0VG.jpg

What can I say - that's ugly!

@ VastOne - di isn't the answer as fstab still has it as an entry, but looks like a nice little app.  Even though it shows root twice it's cleaner and fits on a normal terminal window:

  02 Sep 12 | 16:18:43 ~
         $ di
Filesystem         Mount               Size     Used    Avail %Used  fs Type 
rootfs             /                   9.3G     6.5G     2.3G   75%  rootfs  
/dev/disk/by-uuid/ /                   9.3G     6.5G     2.3G   75%  ext4    
udev               /dev               10.0M     0.0M    10.0M    0%  devtmpfs
/dev/sda7          /home              13.9G     4.1G     9.1G   35%  ext4    
/dev/sda5          /media/5          116.2G    41.0G    69.4G   40%  ext4    
/dev/sda8          /media/8           66.1G     1.1G    61.7G    7%  ext4    
tmpfs              /run              597.5M     0.4M   597.1M    0%  tmpfs   
tmpfs              /run/lock           5.0M     0.0M     5.0M    0%  tmpfs   
tmpfs              /run/shm            1.9G     0.0G     1.9G    0%  tmpfs   

  02 Sep 12 | 16:18:46 ~
         $ 

@ Awebb - who could possibly nail you down.  big_smile  You have a magic way with words that I envy.  However there is no /boot/grub/menu.lst here (grub2), there is however a /etc/default/grub

@ xaos52 - why exactly is is not recommended? I'll tread carefully and NOT touch it! (for the moment)  big_smile

I'm guessing that this is a new 'feature' and not a bug since di shows both as well.


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#6 2012-09-02 19:34:29

Sector11
#!'er to BL'er
From: SR11 Cockpit
Registered: 2010-05-05
Posts: 15,667
Website

Re: [Solved] strange /root entry in 'df -h'

They look the same...

Awebb wrote:

Post your /proc/mounts

rootfs / rootfs rw 0 0
sysfs /sys sysfs rw,nosuid,nodev,noexec,relatime 0 0
proc /proc proc rw,nosuid,nodev,noexec,relatime 0 0
udev /dev devtmpfs rw,relatime,size=10240k,nr_inodes=755020,mode=755 0 0
devpts /dev/pts devpts rw,nosuid,noexec,relatime,gid=5,mode=620 0 0
tmpfs /run tmpfs rw,nosuid,noexec,relatime,size=611844k,mode=755 0 0
/dev/disk/by-uuid/62874c9e-7f1b-4204-a273-f0699e31c62c / ext4 rw,relatime,errors=remount-ro,data=ordered 0 0
tmpfs /run/lock tmpfs rw,nosuid,nodev,noexec,relatime,size=5120k 0 0
tmpfs /run/shm tmpfs rw,nosuid,nodev,noexec,relatime,size=2004980k 0 0
fusectl /sys/fs/fuse/connections fusectl rw,relatime 0 0
/dev/sda7 /home ext4 rw,relatime,data=ordered 0 0
/dev/sda5 /media/5 ext4 rw,relatime,data=ordered 0 0
/dev/sda8 /media/8 ext4 rw,relatime,data=ordered 0 0
rpc_pipefs /var/lib/nfs/rpc_pipefs rpc_pipefs rw,relatime 0 0
Awebb wrote:

and your /etc/mtab

rootfs / rootfs rw 0 0
sysfs /sys sysfs rw,nosuid,nodev,noexec,relatime 0 0
proc /proc proc rw,nosuid,nodev,noexec,relatime 0 0
udev /dev devtmpfs rw,relatime,size=10240k,nr_inodes=755020,mode=755 0 0
devpts /dev/pts devpts rw,nosuid,noexec,relatime,gid=5,mode=620 0 0
tmpfs /run tmpfs rw,nosuid,noexec,relatime,size=611844k,mode=755 0 0
/dev/disk/by-uuid/62874c9e-7f1b-4204-a273-f0699e31c62c / ext4 rw,relatime,errors=remount-ro,data=ordered 0 0
tmpfs /run/lock tmpfs rw,nosuid,nodev,noexec,relatime,size=5120k 0 0
tmpfs /run/shm tmpfs rw,nosuid,nodev,noexec,relatime,size=2004980k 0 0
fusectl /sys/fs/fuse/connections fusectl rw,relatime 0 0
/dev/sda7 /home ext4 rw,relatime,data=ordered 0 0
/dev/sda5 /media/5 ext4 rw,relatime,data=ordered 0 0
/dev/sda8 /media/8 ext4 rw,relatime,data=ordered 0 0
rpc_pipefs /var/lib/nfs/rpc_pipefs rpc_pipefs rw,relatime 0 0
Awebb wrote:

The phenomenon seems to be gone in systemd (new init coming to Linux-land).

Any idea when?  And how did you determine this wonderful news?

KUDOS! out to Awebb


·  ↓   ↓   ↓   ↓   ↓   ↓  ·
BunsenLabs Forums now Open for Registration
·  ↑   ↑   ↑   ↑   ↑   ↑  · BL ModSquad

Offline

#7 2012-09-02 21:19:05

Awebb
The Singularity
Registered: 2009-07-23
Posts: 2,812

Re: [Solved] strange /root entry in 'df -h'

Well, I had the same issue on my Arch box until wednesday, the day I switched to systemd, now it's gone. I don't know if and when Debian will switch to systemd. If you care to try, look up systemd on the Debian wiki and open a thread here. I am willing to help out with what I know, but I am not on Debian.

@xaos52: GRUB_DISABLE_LINUX_UUID does not mean that grub2 stops using UUID's, it means it won't pass the UUID to the linux kernel, which means /proc/mounts will containt the device node instead of the UUID and that means the /etc/mtab won't show UUID's, which means... df will not have to deal with UUID's.

So, Sector11, I don't think this parameter is harmful. I cannot find any hints on it eating hard drives like SliM lol


I'm so meta, even this acronym

Offline

#8 2012-10-22 05:17:20

kbmonkey
#! Die Hard
From: South Africa
Registered: 2011-01-14
Posts: 879
Website

Re: [Solved] strange /root entry in 'df -h'

@Awebb you are correct, the option simply won't pass the root's UUID to the Linux kernel. After turning it on I now get this df output:

kbmonkey@multivac:~$ df
Filesystem        Type      Size  Used Avail Use% Mounted on
rootfs            rootfs    9.3G  2.7G  6.3G  30% /
udev              devtmpfs   10M     0   10M   0% /dev
tmpfs             tmpfs     397M  368K  397M   1% /run
/dev/sda2         ext4      9.3G  2.7G  6.3G  30% /
tmpfs             tmpfs     5.0M     0  5.0M   0% /run/lock
tmpfs             tmpfs     1.9G  152K  1.9G   1% /run/shm
/dev/mapper/vault ext4       19G  2.1G   16G  12% /home
/dev/sda7         ext4      656G  337G  286G  55% /media/data

Much cleaner, much thank you!

Offline

Board footer

Powered by FluxBB

Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.
Server: acrobat

Debian Logo