Fog Crashed this morning... When i try to connect => Database Schema Installer / Updater



  • Hi,
    i have a big problem… Yesterday before leaving from work, i ran an image and this morning i was checking the size of the file of the image on the web interface and it was written 0.
    So i checked the filesystem, it looks correct except the permissions on the files. For some images folder it was “fog” the owner (the one with size 0 if i m remember well) and other with root.
    So i ran this:
    chmod -R 777 /images
    chown -R root:root /images

    I went back on the web interface and i m redirected to the page:
    http://xxxxx/fog/commons/schemaupdater/index.php?redir=1

    i tried to make the backup:
    root@ubufog:/opt/fog/utils# cd ~;mysqldump --allow-keywords -x -v fog > fogbackup.sql
    – Connecting to localhost…
    mysqldump: Got error: 2002: Can’t connect to local MySQL server through socket ‘/var/run/mysqld/mysqld.sock’ (2) when trying to connect

    and i got also that message:
    fog Can’t get stat of ‘./fog’ (Errcode: 13)

    So I don t know what to do… New installation is maybe the only way BUT i need to keep all my images. Is it possible to restore them in a new installation ?

    For sure when it ll be working again, i ll run every day a backup like written in the wiki…

    thx…



  • @Wayne-Workman Hint received. Just figured since I have an identical issue that I’d keep it all within a single thread.


  • Moderator

    @Rich-C Or you could fix it, and ask for help with doing that in a new thread. ;-)


  • Moderator

    @Rich-C Assuming you have a good copy of your images and your database you can basically reinstall your OS, install FOG, put the images back, then restore the database and everything is the way it should be.



  • @raymondub I realize that this topic is very old but in theory this SHOULD work…has anyone confirmed this as a viable solution to recovering from a server failure if you have a good copy of your images?



  • well thank for your advice but i didn t work…
    I made a very bad manipulation… I wanted to change the ownership and rights just on /images but it s seems that i forgot to write images and thus all the rights have been changed on the whole filesystem.
    So i tried to capture ownerships and rights from my other serveur to overwrite on this one.
    Scratch fog installation by remove all php* and mysql* package
    Reinstall fog
    install some missing php package
    and… it s working again…
    But my server is like “cheese” with too many permissions…
    But at least i can take a backup and put it on a new server…
    :-)


  • Senior Developer

    Or,

    Follow the instructions found here:

    https://github.com/fogproject/fogproject/issues/1



  • what if:

    1. i make a NEW installation
    2. i create image with the same name of on my prod installation except that to make it quicker, i ll capture image of small vm windows 7
    3. I replace the images folder on the new server with the “old” image server
      Will it work ?
      I don t care of the existing mac address, hostname,… I just need to get back my images working




  • root@ubufog:~# vi /var/log/mysql/error.log
    150312 8:40:39 [ERROR] /usr/sbin/mysqld: Can’t find file: ‘./fog/groupMembersTemp.frm’ (errno: 13)
    150312 8:40:39 [ERROR] /usr/sbin/mysqld: Can’t find file: ‘./fog/groupMembersTemp.frm’ (errno: 13)
    150312 8:41:03 [ERROR] /usr/sbin/mysqld: Can’t find file: ‘./fog/groupMembersTemp.frm’ (errno: 13)
    150312 8:41:03 [ERROR] /usr/sbin/mysqld: Can’t find file: ‘./fog/groupMembersTemp.frm’ (errno: 13)
    150312 8:41:18 [Note] /usr/sbin/mysqld: Normal shutdown

    150312 8:41:18 [Note] Event Scheduler: Purging the queue. 0 events
    150312 8:41:20 [Warning] /usr/sbin/mysqld: Forcing close of thread 9147 user: ‘root’

    150312 8:41:20 [Warning] /usr/sbin/mysqld: Forcing close of thread 2 user: ‘root’

    150312 8:41:20 [Warning] /usr/sbin/mysqld: Forcing close of thread 1 user: ‘root’

    150312 8:41:20 InnoDB: Starting shutdown…
    150312 8:41:21 InnoDB: Shutdown completed; log sequence number 1773129
    150312 8:41:22 [Note] /usr/sbin/mysqld: Shutdown complete


Log in to reply
 

Looks like your connection to FOG Project was lost, please wait while we try to reconnect.