Difference between revisions of "Upgrade to quantal"

From Finninday
Jump to: navigation, search
(Created page with "testing")
 
Line 1: Line 1:
testing
+
<pre>
 +
sofficerc
 +
take new version
 +
 
 +
/etc/gdm/custom.conf
 +
take new verison
 +
 
 +
dpkg problem report to developers
 +
including /etc/hobbit/clientlaunch.cfg
 +
problem in xymon-client
 +
problem cannot be reported.  you have already encountered this package installation failure.
 +
 
 +
upgrade did not complete.
 +
rebooted
 +
came up clean
 +
xymon was not running
 +
 
 +
couldn't find any installer logs that told more about the failure or current state
 +
 
 +
ran apt-get upgrade to clean up
 +
2 packages not fully installed or removed
 +
setting up xymon-client
 +
crash, maxreports is already reached
 +
 
 +
apt-get autoremove: 139 packages
 +
failed to configure xymon-client
 +
 
 +
dpk-reconfigure xymon-client
 +
xymon-client is broken or not fully installed
 +
 
 +
found a bug on launchpad (1069227) that said a fix was to have a process running as hobbit that the script could kill.  This worked and apt-get now reports that all packages are installed.
 +
 
 +
wiki and hobbit are not running.
 +
 
 +
A database error has occurred. Did you forget to run maintenance/update.php after upgrading? See: https://www.mediawiki.org/wiki/Manual:Upgrading#Run_the_update_script
 +
Query: SELECT lc_value FROM `mw_l10n_cache` WHERE lc_lang = 'en' AND lc_key = 'deps' LIMIT 1
 +
Function: LCStore_DB::get
 +
Error: 1146 Table 'wikidb.mw_l10n_cache' doesn't exist (localhost)
 +
 
 +
php maintenance/update.php
 +
 
 +
fixed it.
 +
 
 +
trying to create a new page fails with a page reset.
 +
 
 +
The apache error logs show child pid exit signal segmentation fault (11)
 +
 
 +
trying to get to xymon generates this error in apache error logs:
 +
file does not exist: /var/lib/hobbit
 +
 
 +
 
 +
did apt-get remove xymon
 +
apt-get install xymon
 +
 
 +
that didn't get me much closer
 +
I was left with lots of broken links as a result of the name change from hobbit to xymon
 +
 
 +
apt-get purge xymon
 +
apt-get install xymon
 +
that didn't seem to work either, but after five minutes it ran and showed a working clean install
 +
Now I need to restore my custom configs, but in xymon directories instead of hobbit directories
 +
 
 +
first, rewrite puppet module that pushes my config for hobbit
 +
 
 +
lost my cputemp, heater, and bandwidth scripts, so must rewrite them
 +
 
 +
puppet module is much cleaner now, controlling just custom snippets instead of files that will be overwritten with the next upgrade.
 +
 
 +
lost ability to view the recipebook.  Trying to view a page yields a blank page with no error.  The apache error logs show a php seg fault: PHP Fatal error: Call to undefined function session_register() in /var/www/phprecipebook-3.01/libs/phpsm/core_API.php on line 94
 +
 
 +
The session_register() function is deprecated in php 5.3 and removed in php 5.4
 +
I happen to be using php 5.4.6 now.
 +
 
 +
Upgraded to the latest code for phprecipebook (4.04b) and the error is still present.
 +
 
 +
The line of code is:
 +
session_register($g_sm_session_id);
 +
 
 +
phpdocs (php.net/manual/en/function.session-register.php) say that the prefered use is
 +
$_SESSION["zim"] = "An invader from another planet.";
 +
 
 +
commenting out the session_register() function got the app to come up without a session
 +
But nothing is visible in the database.
 +
 
 +
A schema upgrade is required.  I found the script in sql/upgrade
 +
mysql --user=root --password=password food <recipedb-3.00-4.00.sql
 +
ERROR 1060 at line 104: Duplicate column name 'restaurant_website'
 +
 
 +
did it work? no, it appears nothing happened.
 +
Actually something happened.  The script is not idempotent so I must create a new script
 +
to make the changes that were not made by the previous run.
 +
 
 +
The schema update completed after I eliminated the changes that had previously been made.
 +
But the site does not populate with any data from mysql.
 +
Apache error log shows
 +
mysql_pconnect(): Can't connect to local MySQL server through socket '/var/lib/mysqld/mysqld.sock' (2) in /var/www/food/libs/ad0db5/drivers/adodb-mysql.inc.php on line 383, referer: http://www.finninday.net/food/index.php
 +
 
 +
has mysql changed?
 +
/etc/mysql/my.cnf looks like the new location of the socket is /var/run/mysqld/mysqld.sock
 +
making the corresponding change in custom_inc.php makes the site display all our hard-won recipes.  phew.
 +
 
 +
But all my restaurant reviews are gone.  Bummer.
 +
 
 +
The query that displays restaurants looks like this:
 +
select * from $db_table_restaurants left join $db_table_prices on price_id =
 +
restaurant_price
 +
where restaurant_user = '" . $DB_LINK->addq($SMObj->getUserID(), get_magic_quotes_gpc()) ."'
 +
order by restaurant_name";
 +
 
 +
That query is in modules/restaurant/index.php
 +
 
 +
select * from recipe_restaurants; shows 51 in the table.
 +
 
 +
It looks like I can't see anything without a session object.  So I should work on fixing the session problem first.
 +
 
 +
 
 +
Log rotate appears wacky.  The most recent apache2/access.log is access.log.1.  access.log exists, but is empty.
 +
 
 +
Trying to restart apache gives a configuration error.  configtest failed.
 +
syntax error on line 62 of conf.d/xymon
 +
Xymon was relying on the rewrite module being enabled, but it wasn't.  Now a restart works and the log rotation looks good.
 +
 
 +
I can log into the recipebook now and make changes, but still no restaurants are displayed.
 +
When logged in the query sees me as user 3 when all the restaurants are set to user 1, so none are displayed.
 +
 
 +
Trying to log out triggers a white screen and a fatal php error: call to undefined
 +
function session_unregister() on phpSM.class.php line 265
 +
 
 +
Removing the where clause which limits by userid, I get to see all the restaurants which is the behavior I want.  We should all share our restaurant reviews, not horde them to ourselves.
 +
 
 +
Commented out the session_unregister() and now login and logout function without error.
 +
</pre>

Revision as of 19:28, 24 March 2013

sofficerc
take new version

/etc/gdm/custom.conf
take new verison

dpkg problem report to developers
including /etc/hobbit/clientlaunch.cfg
problem in xymon-client
problem cannot be reported.  you have already encountered this package installation failure.

upgrade did not complete.
rebooted
came up clean
xymon was not running

couldn't find any installer logs that told more about the failure or current state

ran apt-get upgrade to clean up
2 packages not fully installed or removed
setting up xymon-client
crash, maxreports is already reached

apt-get autoremove: 139 packages
failed to configure xymon-client

dpk-reconfigure xymon-client
xymon-client is broken or not fully installed

found a bug on launchpad (1069227) that said a fix was to have a process running as hobbit that the script could kill.  This worked and apt-get now reports that all packages are installed.

wiki and hobbit are not running.

A database error has occurred. Did you forget to run maintenance/update.php after upgrading? See: https://www.mediawiki.org/wiki/Manual:Upgrading#Run_the_update_script
Query: SELECT lc_value FROM `mw_l10n_cache` WHERE lc_lang = 'en' AND lc_key = 'deps' LIMIT 1
Function: LCStore_DB::get
Error: 1146 Table 'wikidb.mw_l10n_cache' doesn't exist (localhost)

php maintenance/update.php

fixed it.

trying to create a new page fails with a page reset.

The apache error logs show child pid exit signal segmentation fault (11)

trying to get to xymon generates this error in apache error logs:
file does not exist: /var/lib/hobbit


did apt-get remove xymon
apt-get install xymon

that didn't get me much closer
I was left with lots of broken links as a result of the name change from hobbit to xymon

apt-get purge xymon
apt-get install xymon
that didn't seem to work either, but after five minutes it ran and showed a working clean install
Now I need to restore my custom configs, but in xymon directories instead of hobbit directories

first, rewrite puppet module that pushes my config for hobbit

lost my cputemp, heater, and bandwidth scripts, so must rewrite them

puppet module is much cleaner now, controlling just custom snippets instead of files that will be overwritten with the next upgrade.

lost ability to view the recipebook.  Trying to view a page yields a blank page with no error.  The apache error logs show a php seg fault: PHP Fatal error: Call to undefined function session_register() in /var/www/phprecipebook-3.01/libs/phpsm/core_API.php on line 94

The session_register() function is deprecated in php 5.3 and removed in php 5.4
I happen to be using php 5.4.6 now.

Upgraded to the latest code for phprecipebook (4.04b) and the error is still present.

The line of code is:
	session_register($g_sm_session_id);

phpdocs (php.net/manual/en/function.session-register.php) say that the prefered use is
	$_SESSION["zim"] = "An invader from another planet.";

commenting out the session_register() function got the app to come up without a session
But nothing is visible in the database.

A schema upgrade is required.  I found the script in sql/upgrade
mysql --user=root --password=password food <recipedb-3.00-4.00.sql
ERROR 1060 at line 104: Duplicate column name 'restaurant_website'

did it work? no, it appears nothing happened.
Actually something happened.  The script is not idempotent so I must create a new script
to make the changes that were not made by the previous run.

The schema update completed after I eliminated the changes that had previously been made.
But the site does not populate with any data from mysql.
Apache error log shows
mysql_pconnect(): Can't connect to local MySQL server through socket '/var/lib/mysqld/mysqld.sock' (2) in /var/www/food/libs/ad0db5/drivers/adodb-mysql.inc.php on line 383, referer: http://www.finninday.net/food/index.php

has mysql changed?
/etc/mysql/my.cnf looks like the new location of the socket is /var/run/mysqld/mysqld.sock
making the corresponding change in custom_inc.php makes the site display all our hard-won recipes.  phew.

But all my restaurant reviews are gone.  Bummer.

The query that displays restaurants looks like this:
select * from $db_table_restaurants left join $db_table_prices on price_id =
restaurant_price 
where restaurant_user = '" . $DB_LINK->addq($SMObj->getUserID(), get_magic_quotes_gpc()) ."'
order by restaurant_name";

That query is in modules/restaurant/index.php

select * from recipe_restaurants; shows 51 in the table.

It looks like I can't see anything without a session object.  So I should work on fixing the session problem first.


Log rotate appears wacky.  The most recent apache2/access.log is access.log.1.  access.log exists, but is empty.

Trying to restart apache gives a configuration error.  configtest failed.
syntax error on line 62 of conf.d/xymon
Xymon was relying on the rewrite module being enabled, but it wasn't.  Now a restart works and the log rotation looks good.

I can log into the recipebook now and make changes, but still no restaurants are displayed.
When logged in the query sees me as user 3 when all the restaurants are set to user 1, so none are displayed.

Trying to log out triggers a white screen and a fatal php error: call to undefined 
function session_unregister() on phpSM.class.php line 265

Removing the where clause which limits by userid, I get to see all the restaurants which is the behavior I want.  We should all share our restaurant reviews, not horde them to ourselves.

Commented out the session_unregister() and now login and logout function without error.