Fedora Linux Support Community & Resources Center

Go Back   FedoraForum.org > Fedora 17/18 > Using Fedora
FedoraForum Search

Forgot Password? Join Us!

Using Fedora General support for current versions. Ask questions about Fedora and it's software that do not belong in any other forum.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 18th November 2011, 04:26 PM
bswilson's Avatar
bswilson Offline
Registered User
 
Join Date: Jan 2008
Age: 39
Posts: 5
linuxfirefox
Requesting help mounting a directory at system startup time

Friends,

I need some help to solve a weird problem. I recently switched from Ubuntu to Fedora, after using Ubuntu for about 8 years. I've found Fedora really great. However, when I built my brand new Fedora box, I decided to mount a different disk as /media to house my music, videos, and photos. On my old Ubuntu system, I kept some of this in my home directory and that isn't terribly efficient, etc. The problem is, when I boot my computer, /media is not mounted. When I issue the command sudo mount /media, it mounts with no problem. How can I set my computer up so that /media mounts when I start/reboot my computer?

Here are some data points.

Output of /etc/fstab after booting:

Code:
#
# /etc/fstab
# Created by anaconda on Sat Sep 17 07:44:12 2011
#
# Accessible filesystems, by reference, are maintained under '/dev/disk'
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info
#
/dev/mapper/vg_eminem-lv_root /                       ext4    defaults        1 1
UUID=1abb75a9-8635-4916-b52e-d82778407c2f /backup                 ext4    defaults        1 2
UUID=b32a3c77-c6a1-46cd-830c-cbacc05e7754 /boot                   ext4    defaults        1 2
/dev/mapper/vg_eminem-lv_home /home                   ext4    defaults        1 2
UUID=180f4025-92f9-4087-b4dd-4adbe77686c2 /media                  ext4    defaults        1 2
/dev/mapper/vg_eminem-lv_swap swap                    swap    defaults        0 0
tmpfs                   /dev/shm                tmpfs   defaults        0 0
devpts                  /dev/pts                devpts  gid=5,mode=620  0 0
sysfs                   /sys                    sysfs   defaults        0 0
proc                    /proc                   proc    defaults        0 0
Output of df -h |grep media after booting:

Code:
tmpfs                 3.9G     0  3.9G   0% /media
Output of mount command after booting:

Code:
tmpfs on /media type tmpfs (rw,nosuid,nodev,noexec,relatime,rootcontext=system_u:object_r:mnt_t:s0,seclabel,mode=755)
After I run the command sudo mount /media, the output of mount looks like this:

Code:
tmpfs on /media type tmpfs (rw,nosuid,nodev,noexec,relatime,rootcontext=system_u:object_r:mnt_t:s0,seclabel,mode=755)
/dev/sdb2 on /media type ext4 (rw,relatime,seclabel,user_xattr,barrier=1,data=ordered)
Can anyone guide me, please?
Reply With Quote
  #2  
Old 18th November 2011, 04:43 PM
surmabhopali Offline
Registered User
 
Join Date: Aug 2011
Location: India
Age: 27
Posts: 36
linuxfirefox
Re: Requesting help mounting a directory at system startup time

the defaults options in fstab is "rw, suid, dev, exec, auto, nouser, and async"...and "nouser" means that only root can mount the device...so according to me you should try changing "defaults" i.e. fourth column this link may help..

http://www.tuxfiles.org/linuxhelp/fstab.html
Reply With Quote
  #3  
Old 18th November 2011, 04:50 PM
jpollard Offline
Registered User
 
Join Date: Aug 2009
Location: Waldorf, Maryland
Posts: 6,108
linuxfedorafirefox
Re: Requesting help mounting a directory at system startup time

What release of fedora are you using?

Fedora 15/16 moves /media to a memory disk that is handled by udev.

If you want something mounted permanently you need to mount it somewhere else - one suggestion is a mountpoint in /mnt (such as /mnt/media) instead of /media.

/media is now aimed at SD cards and other external USB storage. These should be automatically mounted as /media/<name> where name may be taken from the storage media. Internal disks (such as those listed in /etc/fstab) have to be mounted elsewhere.
Reply With Quote
  #4  
Old 18th November 2011, 04:58 PM
Gareth Jones Offline
Official Gnome 3 Sales Rep. (and Adminstrator)
 
Join Date: Jul 2011
Location: Leamington Spa, UK
Age: 30
Posts: 1,711
linuxfirefox
Re: Requesting help mounting a directory at system startup time

Quote:
Originally Posted by jpollard View Post
/media is now aimed at SD cards and other external USB storage.
To be fair, /media was added to the FHS specifically for this purpose. "Media" mean CDs, DVDs, external storage devices etc., not "multimedia".

So yes, use a non-system directory, such as /mnt or /mnt/media etc.

Gareth
Reply With Quote
  #5  
Old 18th November 2011, 06:24 PM
bswilson's Avatar
bswilson Offline
Registered User
 
Join Date: Jan 2008
Age: 39
Posts: 5
windows_7firefox
Re: Requesting help mounting a directory at system startup time

Ah, I see! Yes, I'm using Fedora 15. I did not know this about /media, so I'll change that and report how it goes. Thank you!

---------- Post added at 01:24 PM ---------- Previous post was at 12:06 PM ----------

All, I was able to execute mv /media/* /mnt/media/* and now my system works perfectly. Thank so much for the help.
Reply With Quote
  #6  
Old 19th November 2011, 02:13 PM
marvin_ita Offline
Registered User
 
Join Date: Jun 2007
Location: Como - Italy
Posts: 248
linuxfirefox
Re: Requesting help mounting a directory at system startup time

Quote:
Originally Posted by bswilson View Post
All, I was able to execute mv /media/* /mnt/media/* and now my system works perfectly. Thank so much for the help.
Maybe I'm missing something... with the command mv you moved all the data you had on the secondary disk onto the primary disk in the /mnt/media folder. Now you don't have the data in the secondary disk, but in the primary, and the secondary disk is not mounted at startup in the /mnt/media folder!
Is it this you wanted?
Reply With Quote
  #7  
Old 19th November 2011, 08:20 PM
Gareth Jones Offline
Official Gnome 3 Sales Rep. (and Adminstrator)
 
Join Date: Jul 2011
Location: Leamington Spa, UK
Age: 30
Posts: 1,711
linuxfirefox
Re: Requesting help mounting a directory at system startup time

Quote:
Originally Posted by bswilson View Post
All, I was able to execute mv /media/* /mnt/media/* and now my system works perfectly. Thank so much for the help.
Yes, that confused me too.

Have you now got your media partition mounted on /mnt/media (and listed in /etc/fstab)? And were the files previously somehow copied into the tmpfs mounted on /media? Unless we're missing something, you'd better check that everything is indeed where you think it is!

Gareth
Reply With Quote
  #8  
Old 2nd December 2011, 02:25 PM
bswilson's Avatar
bswilson Offline
Registered User
 
Join Date: Jan 2008
Age: 39
Posts: 5
linuxfirefox
Re: Requesting help mounting a directory at system startup time

Gareth, you and marvin_ita are absolutely correct. I don't think I have things set up the way I want. I am going to start a new thread to get additional help.

It does appear that now my /mnt/media/ folder is in the same logical volume group as /home, which means I really have all my stuff on the same physical disk, which is not what I want.

Thank you.
Reply With Quote
  #9  
Old 2nd December 2011, 03:08 PM
surmabhopali Offline
Registered User
 
Join Date: Aug 2011
Location: India
Age: 27
Posts: 36
linuxfirefox
Re: Requesting help mounting a directory at system startup time

first copy your all /media back to where it was....and then edit fstab...
Reply With Quote
Reply

Tags
disk, fstab, mount, partition, tmpfs

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
The system date and time is changing automatically, even after I set the correct time siva Using Fedora 8 31st July 2010 03:07 PM
Building a new workstation, requesting system design advice.. juanzo007 Using Fedora 1 18th January 2008 03:49 AM
Mounting a directory as a CD calvarymanagua Using Fedora 0 19th June 2006 05:18 PM


Current GMT-time: 08:11 (Saturday, 25-05-2013)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat