LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   Device won't mount during boot - CentOS 5.4 on Amazon EC2 instance (https://www.linuxquestions.org/questions/linux-server-73/device-wont-mount-during-boot-centos-5-4-on-amazon-ec2-instance-863084/)

s_elkind 02-16-2011 10:52 AM

Device won't mount during boot - CentOS 5.4 on Amazon EC2 instance
 
I'm having a consistent problem with instances on Amazon EC2, which a lot of searching including here has resulted in no solution.

During boot I see the following message on the console (or "System Log" in the Amazon console):

Code:

Mounting local filesystems:  mount: /dev/sdg already mounted or /apps busy
(I'll append a extract from the full log below).

Once I log into the instance, I can access the filesystem so it's mounted somehow but I can't figure out what's going on:
Code:

# df -k /apps
Filesystem          1K-blocks      Used Available Use% Mounted on
-                    20642428    176208  19417644  1% /apps

If I force an unmount of the filesystem, then remount it then appears more normal:
Code:

# umount -f /apps
# mount -a
# df -k /apps
Filesystem          1K-blocks      Used Available Use% Mounted on
/dev/sdg              20642428    176208  19417644  1% /apps
#

Here's what's in /etc/fstab:

Code:

# cat /etc/fstab
/dev/sda1  /        ext3    defaults        0 0
/dev/sdb  /mnt      ext3    defaults        0 0
none      /dev/pts  devpts  gid=5,mode=620  0 0
none      /dev/shm  tmpfs  defaults        0 0
none      /proc    proc    defaults        0 0
none      /sys      sysfs  defaults        0 0
/swapfile1 swap      swap    defaults        0 0
/dev/sdg  /apps      ext3    defaults,noatime 0 0
#

Can anyone suggest some ideas of what's going on here? Or how to troubleshoot? I'd like to be able to start these up without having to login to fix things up manually.

===================== System Log Extract ==========
(elisions where I removed uninteresting stuff)
Code:

                Welcome to  CentOS release 5.4 (Final)
                Press 'I' to enter interactive startup.
Cannot access the Hardware Clock via any known method.
Use the --debug option to see the details of our search for an access method.
Setting clock : Wed Feb 16 10:04:30 EST 2011 [  OK  ]

Starting udev: [  OK  ]

Setting hostname localhost.localdomain:  [  OK  ]

No devices found
Setting up Logical Volume Management: File descriptor 7 (/sys/kernel/hotplug) leaked on lvm.static invocation. Parent PID 231: /bin/bash
[  OK  ]

Checking filesystems
Checking all file systems.
[  OK  ]

Remounting root filesystem in read-write mode:  [  OK  ]

Mounting local filesystems:  mount: /dev/sdg already mounted or /apps busy
[FAILED]

Enabling local filesystem quotas:  [  OK  ]

Enabling /etc/fstab swaps:  [  OK  ]

INIT: Entering runlevel: 4

Entering non-interactive startup
Starting background readahead: [  OK  ]

Bringing up loopback interface:  [  OK  ]

Bringing up interface eth0: 
Determining IP information for eth0... done.
[  OK  ]

...

Starting syslog-ng: [  OK  ]

Starting system message bus: [  OK  ]

Mounting other filesystems:  mount: /dev/sdg already mounted or /apps busy
[FAILED]

Starting HAL daemon: [  OK  ]

...


jcalzare 02-17-2011 08:22 PM

I had this issue when I wrote some deployment scripts for ec2. I ended up adding a sleep timer in between instance activation, and mounting the EBS volumes. I guess it's sort of a hack, but it worked for me.


All times are GMT -5. The time now is 04:42 AM.