[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [cobalt-users] [RaQ4] Gui Problems too!



William J.A. Brillinger schrieb:

> ok, wierd. This morning one of my servers was working fine - now it
> has choked.
>
> Http & postgres died but I was able to get into the GUI and reboot.
> Httpd came back up but I have an internal server error on sitelist.cgi.
>
> I checked adm_error and found this:
>
> [Wed May 28 19:38:31 2003] [notice] suEXEC mechanism enabled (wrapper:
> /usr/sbin/suexec)
> Can't call method "exec" on an undefined value at
> /usr/lib/perl5/site_perl/5.005/Cobalt/Meta.pm line 770.
> [Wed May 28 19:41:06 2003] [error] [client 142.161.212.32] Premature
> end of script headers: /usr/admserv/cgi-bin/.cobalt/siteList/siteList.cgi
> Can't call method "exec" on an undefined value at
> /usr/lib/perl5/site_perl/5.005/Cobalt/Meta.pm line 770.
> [Wed May 28 19:48:46 2003] [error] [client 142.161.212.32] Premature
> end of script headers: /usr/admserv/cgi-bin/.cobalt/siteList/siteList.cgi
>
> I ran /usr/local/sbin/meta-verify -f
> and Got this:
>
> meta-verify (version 3.0)
> (c) 2000 Cobalt Networks, Inc
>
> checking VIRTUAL SITES
> repairing 1 INVALID VIRTUAL SITES
>
> Can't call method "exec" on an undefined value at
> /usr/lib/perl5/site_perl/5.005/Cobalt/Meta.pm line 1479.
>
>
> The server has also just emailed me again that "The PostgreSQL server
> is down and cannot be restarted."
>
> Suggestions??
> - Bill B.
>
> I also checked /var/log/postgresql and found this:
>
> 030528.20:00:00.490  [1674] DEBUG:  Data Base System is starting up at
> Wed May 28 20:00:00 2003
> 030528.20:00:00.490  [1674] FATAL 2:  Control file context is broken
> 030528.20:00:00.490  [1674] FATAL 2:  Control file context is broken
> Startup failed - abort
>
> <snip>

"FATAL 2: Control file context is broken "

This error may indicate that one of three fields in pg_control has a
broken value. Not sure how it could have
gotten that way but maybe the only failures is of a field involve a
wrong timestamp.
Is it possible that the system clock was set to a silly value (in
example lower than 1970) last time you shut down?

Check if PSQL could find your data directory. Is your database directory
in /var/lib/pgsql/data/base/cobalt ?

Maybe one way for fixing this is to initdb a fresh database directory
and then use pg_upgrade to move your
existing user data into the new database, but this should be the last
step after reading the pg_upgrade manual carefully.
Another answer may be to alter the source of the PSQL file xlog.c is
where the check happens and recompile.
Or maybe try pg_resetxlog which reset write-ahead log and pg_control
contents.

Did you have a Backup of you Cobalt Database ?

Note that you can get a backup of it with:

su --login --command="cd ~ ; \
mkdir /tmp/postgres ; \
chown postgres:postgres /tmp/postgres ; \
mv data/pg_hba.conf /tmp/postgres/pg_hba.conf.bak ; \
echo 'local cobalt trust' > data/pg_hba.conf ; \
pg_dump -d cobalt > /tmp/postgres/cobalt.pgsql ; \
mv /tmp/postgres/pg_hba.conf.bak data/pg_hba.conf" postgres

regards