The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

read only files systems muffed up sql and apache

Discussion in 'Database Discussions' started by 21Century, Jul 1, 2007.

  1. 21Century

    21Century Member

    Joined:
    Aug 16, 2004
    Messages:
    20
    Likes Received:
    0
    Trophy Points:
    1
    Hi guys

    big problem

    sql is not working and saying it is unable to connect to local host and when applying apache its saying that all usr and tmps are read only file systems it was completely fine before i went away and now its screwed

    please could you help

    thanks,
     
  2. BeDazzler

    BeDazzler Member

    Joined:
    Feb 20, 2006
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Australia
    Hi There,

    We have come across this once before.
    The server was a HP / Compaq with a RAID1 disk system.

    One of the disks in the RAID1 set went bad, so the RAID controller marked the disks read only.

    Not sure if the whole filesystem is read only for you.

    Regards,

    Darren.
     
  3. madaboutlinux

    madaboutlinux Well-Known Member

    Joined:
    Jan 24, 2005
    Messages:
    1,052
    Likes Received:
    2
    Trophy Points:
    38
    Location:
    Earth
    Such issues can actually be solved by logging to the server. But still if you provide more info people here can help you a bit better.

    Paste the output of the commands:

    mysql << Its for connecting Mysql server.
    /etc/init.d/httpd configtest
    /etc/init.d/httpd restart

    It is possible that your server was rebooted and the partitions were mounted readonly. You can try the 'mount' command to mount the partitions as read/write.

    mount -t ext2 -o rw,remount /dev/hdaxx

    where,

    xx is the partition number.
     
  4. Spiral

    Spiral BANNED

    Joined:
    Jun 24, 2005
    Messages:
    2,023
    Likes Received:
    7
    Trophy Points:
    0
    Linux based systems will automatically remount volumes as read-only if a
    critical error is detected in the filesystem either from a pending drive failure
    or corruption in the partition(s).

    In that case, you should unmount the drives and run "fsck" to scan the drive
    and find out what is going on and to get it out of "read only" status.

    It would be wise to make a full backup of your drive as soon as possible
    in case the read only was triggered by a pending drive failure.

    Now with that said ...

    It could also be as simple as your /tmp partition is just full!

    To check your drive usage, you can run "df -h"
     
  5. chirpy

    chirpy Well-Known Member

    Joined:
    Jun 15, 2002
    Messages:
    13,475
    Likes Received:
    20
    Trophy Points:
    38
    Location:
    Go on, have a guess
    That's usually not a good idea. As Spiral has said, it's a protection mechanism that Linux uses to protect corrupt filesystems (if it's not just /tmp that's full or broken) in which case you should not tey and remount the volume RW as this could lead immediately to partition data corruption.

    The correct course of action, as Spiral has said, is to ensure you have a good backup of your data and then run an FSCK on the disk either by dismounting or via a reboot with forced FSCK. If the FSCK fails, you'll need to get the disk replaced as it's then most likely a disk fault/head crash.
     
  6. madaboutlinux

    madaboutlinux Well-Known Member

    Joined:
    Jan 24, 2005
    Messages:
    1,052
    Likes Received:
    2
    Trophy Points:
    38
    Location:
    Earth
    Thanks Chirpy for corrceting me.
     
Loading...

Share This Page