Registrations to Open-AudIT forums are now closed. To ask any new questions please visit Opmantek Community Questions.

Open-AudIT

What's on your network?
It is currently Sun Apr 21, 2024 1:50 am

All times are UTC + 10 hours




Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 12 posts ] 
Author Message
PostPosted: Wed Oct 15, 2008 4:57 am 
Offline
Contributor

Joined: Fri Sep 28, 2007 12:07 am
Posts: 189
Hi,

There is a bug in the upgrade.php script related to today's SVN update.

File: upgrade.php
Symptom: When you click on "New version found. Click here to upgrade!" you receive an error (PHP) like so:
[code]
Parse error: syntax error, unexpected T_STRING blah blah at Line 450
[/code]

Line 450 is not the problem. Problem is at line 448 which reads:

[code]
) ENGINE=MyISAM DEFAULT CHARSET=latin1;"
[/code]

should be:

[code]
) ENGINE=MyISAM DEFAULT CHARSET=latin1";
[/code]

Save and now you can run the upgrade.

Take care.

Jason

_________________
OA Deployment:
Windows 2003 with XAMPP install
80 Windows Servers
250 Windows workstations (mixed XP and 2000)
5 MACs
Multiple printers, switches, routers, firewalls, and other servers (ESX, AIX etc.)


Top
 Profile  
Reply with quote  
PostPosted: Thu Oct 16, 2008 6:37 pm 
Offline
Moderator
User avatar

Joined: Tue Jan 25, 2005 3:09 am
Posts: 2140
Location: Scotland
:oops: I uploaded an earlier version of Nick's code, and then ran in to an issue updating it to the latest version, try it now.

_________________
Andrew

[size=85]OA Server: Windows XP/ XAMPP, Mandriva/Apache, Ubuntu
Auditing: 300+ Wstns, 20+ Srvrs, Thin clients, Linux boxes, Routers, etc
OS's: Windows XP , W2K Srvr, W2K3 Srvr, W2K8, Vista, Windows 7, Linuxes (and a Mac at home)
LDAP: Active Directory[/size]


Top
 Profile  
Reply with quote  
PostPosted: Thu Oct 16, 2008 10:52 pm 
Offline
Helper

Joined: Thu Dec 08, 2005 6:33 pm
Posts: 87
Location: Germany, BaW
I´ve updated to the actual snv, but still get this error:

[quote]Upgrading to 08.10.08..............Query failed: CREATE TABLE `openaudit`.`log` ( `log_id` int(10) unsigned NOT NULL auto_increment, `log_timestamp` varchar(45) NOT NULL, `log_message` varchar(1024) NOT NULL, `log_severity` int(10) unsigned NOT NULL, `log_module` varchar(128) NOT NULL, `log_function` varchar(128) NOT NULL, PRIMARY KEY (`log_id`), ) ENGINE=MyISAM DEFAULT CHARSET=latin1
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') ENGINE=MyISAM DEFAULT CHARSET=latin1' at line 9

_________________
OA Deployment:
w2k3 R2 with XAMPP install
Windows Servers incl. VM
Windows workstations (XP and Vista, 7)
Multiple printers, switches, routers, firewalls
ADS 1HQ and 20 branches
-------------------
OAv2
w2k8 R2 with XAMPP install


Top
 Profile  
Reply with quote  
PostPosted: Thu Oct 16, 2008 11:02 pm 
Offline
Contributor

Joined: Fri Jul 28, 2006 6:30 am
Posts: 157
Location: London
Line 441 of upgrade.php is
[code]
DROP TABLE IF EXISTS `openaudit`.`log`;
CREATE TABLE `openaudit`.`log` (
[/code]
And should be ...
[code]
DROP TABLE IF EXISTS `log`;
CREATE TABLE `log` (
[/code]

See if changing that helps.

Cheers, Nick.


Top
 Profile  
Reply with quote  
PostPosted: Thu Oct 16, 2008 11:37 pm 
Offline
Helper

Joined: Thu Dec 08, 2005 6:33 pm
Posts: 87
Location: Germany, BaW
[quote="NickBrown"]Line 441 of upgrade.php is
[code]
DROP TABLE IF EXISTS `openaudit`.`log`;
CREATE TABLE `openaudit`.`log` (
[/code]
And should be ...
[code]
DROP TABLE IF EXISTS `log`;
CREATE TABLE `log` (
[/code]

See if changing that helps.

Cheers, Nick.


unfortunately not

[color=#0000FF]Upgrading to 08.10.08..............Query failed: CREATE TABLE `log` ( `log_id` int(10) unsigned NOT NULL auto_increment, `log_timestamp` varchar(45) NOT NULL, `log_message` varchar(1024) NOT NULL, `log_severity` int(10) unsigned NOT NULL, `log_module` varchar(128) NOT NULL, `log_function` varchar(128) NOT NULL, PRIMARY KEY (`log_id`), ) ENGINE=MyISAM DEFAULT CHARSET=latin1
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') ENGINE=MyISAM DEFAULT CHARSET=latin1' at line 9[/color]

_________________
OA Deployment:
w2k3 R2 with XAMPP install
Windows Servers incl. VM
Windows workstations (XP and Vista, 7)
Multiple printers, switches, routers, firewalls
ADS 1HQ and 20 branches
-------------------
OAv2
w2k8 R2 with XAMPP install


Top
 Profile  
Reply with quote  
PostPosted: Thu Oct 16, 2008 11:39 pm 
Offline
Contributor

Joined: Fri Jul 28, 2006 6:30 am
Posts: 157
Location: London
Replace lines 441 to 450 of upgrade.php with this:

[code]
DROP TABLE IF EXISTS `log`;
CREATE TABLE `log` (
`log_id` int(10) unsigned NOT NULL auto_increment,
`log_timestamp` varchar(45) NOT NULL,
`log_message` varchar(1024) NOT NULL,
`log_severity` int(10) unsigned NOT NULL,
`log_module` varchar(128) NOT NULL,
`log_function` varchar(128) NOT NULL,
PRIMARY KEY (`log_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;";
[/code]

Should do the trick.

Cheers, Nick.

_________________
Cheers, Nick.

[size=85]OA Server: Windows Server 2003 / Apache 2
Auditing: 1600 Workstations, 200 Servers
OS's: Windows XP / Windows 2000 / Windows 2003 Server / Windows Vista
LDAP: Active Directory[/size]


Top
 Profile  
Reply with quote  
PostPosted: Thu Oct 16, 2008 11:53 pm 
Offline
Helper

Joined: Thu Dec 08, 2005 6:33 pm
Posts: 87
Location: Germany, BaW
thanks

_________________
OA Deployment:
w2k3 R2 with XAMPP install
Windows Servers incl. VM
Windows workstations (XP and Vista, 7)
Multiple printers, switches, routers, firewalls
ADS 1HQ and 20 branches
-------------------
OAv2
w2k8 R2 with XAMPP install


Top
 Profile  
Reply with quote  
PostPosted: Fri Oct 17, 2008 12:20 am 
Offline
Contributor

Joined: Fri Jul 28, 2006 6:30 am
Posts: 157
Location: London
No problem - this fix is in SVN 1070.

Cheers, Nick.

_________________
Cheers, Nick.

[size=85]OA Server: Windows Server 2003 / Apache 2
Auditing: 1600 Workstations, 200 Servers
OS's: Windows XP / Windows 2000 / Windows 2003 Server / Windows Vista
LDAP: Active Directory[/size]


Top
 Profile  
Reply with quote  
PostPosted: Fri Oct 17, 2008 5:37 am 
Offline
Contributor

Joined: Fri Jul 28, 2006 6:30 am
Posts: 157
Location: London
[quote="NickBrown"]No problem - this fix is in SVN 1070.

Cheers, Nick.


Sorry, my bad, it's not in the SVN yet.

_________________
Cheers, Nick.

[size=85]OA Server: Windows Server 2003 / Apache 2
Auditing: 1600 Workstations, 200 Servers
OS's: Windows XP / Windows 2000 / Windows 2003 Server / Windows Vista
LDAP: Active Directory[/size]


Top
 Profile  
Reply with quote  
PostPosted: Fri Oct 17, 2008 11:00 pm 
I just tried to update to the latest svn 1071 release and when performing the upgrade I get the following error.

[code]Upgrading to 08.10.09..Query failed: ALTER TABLE `software` ADD INDEX `Index4`(`software_name`)
BLOB/TEXT column 'software_name' used in key specification without a key length[/code]

Any advice?


Top
  
Reply with quote  
PostPosted: Fri Oct 17, 2008 11:12 pm 
Offline
Contributor

Joined: Fri Jul 28, 2006 6:30 am
Posts: 157
Location: London
What version of MySql are you running?

Cheers, Nick.

_________________
Cheers, Nick.

[size=85]OA Server: Windows Server 2003 / Apache 2
Auditing: 1600 Workstations, 200 Servers
OS's: Windows XP / Windows 2000 / Windows 2003 Server / Windows Vista
LDAP: Active Directory[/size]


Top
 Profile  
Reply with quote  
PostPosted: Fri Oct 17, 2008 11:27 pm 
I'm running 5.0.22

I think I found the problem, software_name was set to type TEXT. It appears that in a clean install it is now created as VARCHAR(256). So after backing up the table I changed the type to varchar(256). I was then able to perform the upgrade.

As a side note, the software view now FLY!.


Top
  
Reply with quote  
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 12 posts ] 

All times are UTC + 10 hours


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group