fogcontroller.class.php Undefined Offset 3 line 1046
I have a slight problem with a FOG on a centos. I managed to get it working up to a point, it can capture an image but then runs into this error:
Reattempting to update Database.... Failed Error Returned: Type 8, File: /var/www/html/fog/lib/fog/fogcontroller.class.php, Line: 1046, Message: Undefined offset: 3, Host: XXX, User: fog
(Where XXX is the IP Address of my FOG)
Then it shows the Kernel variables and settings and wants to reboot within a minute.
I have looked for answers on google and here but I can’t seem to find the right one. The code in the php file wants a fields Array with 3 fields I guess but it only gets Host and Username.
Maybe it would expect a Password in that instance? Could it be jsut a blank password field somewhere?
ynixon last edited by
I tried the password fix and it didn’t help.
Did you manage to overcome this issue?
Thank you, I will do this asap!
@george1421 Here is how I want you to fix it.
When logged in using another linux user account than
- Review the file /opt/fog/.fogsettings (this is a hidden file)
- In that file there is a entry called
- Capture that password. You will need it to reset the FOG server.
Hint: I can tell you its much easier to do these steps by connecting to your fog server using putty from a windows computer. Copy and paste works great using putty (free terminal program).
- Now reset the linux user
fog's password with
sudo passwd fog
- Now go to the FOG WebGUI and FOG Configuration->FOG Settings->TFTP Server and ensure the password listed in FOG_TFTP_FTP_PASSWORD matches the password you collected in step 2.
- While still in the FOG WebGUI goto Storage Management->All Storage Nodes select the
defaultor storage node in question.
- Ensure that Management Password matches the password you collected in step 2.
- Now finally back in the linux console of the fog server, navigate to where your fog installer files are (typ either /root/fogproject or /opt/fogproject) and rerun the installfog.sh script again to fix the remaining bits.
Once these steps have been completed your FOG server should be happy with you again.
AH ok sorry, won’t change anything what is the process? Is there a guide somewhere?
@technotica No linux user is not the same as the database password. Don’t change anything at the moment. There is a process to fix this. If not careful you can make it worse.
Ohh yes, so the fog account on the server may have a different password than the mysql fog account, that is the problem? I will change that password to match then and not use the account anymore!
Let me ask you this, did you change, modify or use the a linux user account called
fog? If so that is your problem. The error message is a bit misleading. Where we typically see this is the IT Admin uses a the fog service account
fogfor system admin. That account is managed by fog and fog gets a bit unhappy if someone changes the password on it.