Help editing column layout

General discussions here

Help editing column layout

Postby c00p » Thu Oct 09, 2008 9:24 pm

I think rsyslogd & phpLogCon are great utilities, thanks for contributing your hard work to the community. I'm having a small issue removing some columns I don't want to see, and it's not obvious (understand, I'm a little slow :oops: ) where I need to do this. I want to remove the ProcessID & MessageType columns from the standard phpLogCon view. If you could just point me some documentation I should be reading that's fine too.

Thanks
c00p
New
 
Posts: 6
Joined: Tue Oct 07, 2008 4:40 pm

phpLogCon professional services

  • Custom phpLogCon configuration?
  • Maintenance Contract?
  • Installation support?

Re: Help editing column layout

Postby alorbach » Fri Oct 10, 2008 9:38 am

Hi c00p,

are you using the UserDB System as described here?
http://new.phplogcon.org/index.php?modu ... asics.html

If not I would recommend to install it, it will enable the phpLogCon Admin Center. With the admin center you can create your own views, and assign them to your sources.

However you can create one single custom view on normal config based installations as well ;), but you need to edit the config.php to do so. Search for this code in your config.php
Code: Select all
//$CFG['Columns'] = array ( SYSLOG_DATE, SYSLOG_FACILITY, SYSLOG_SEVERITY, SYSLOG_HOST, SYSLOG_SYSLOGTAG, SYSLOG_MESSAGETYPE, SYSLOG_MESSAGE );


And replace with this code:
Code: Select all
$CFG['Columns'] = array ( SYSLOG_DATE, SYSLOG_FACILITY, SYSLOG_SEVERITY, SYSLOG_HOST, SYSLOG_SYSLOGTAG, SYSLOG_MESSAGE );


best regards,
Andre Lorbach
User avatar
alorbach
Site Admin
 
Posts: 1029
Joined: Thu Feb 13, 2003 11:55 am

Re: Help editing column layout

Postby c00p » Fri Oct 10, 2008 1:38 pm

Thanks for the reply. I had tried editing that field before and it didn't remove that field. I tried it again with no luck. I'll try setting up the userdb and see if that works any better. Everything else I've tweaked in the config.php has worked just fine, but removing those two fields is giving me fits. The other reason I thought it might be somewhere else, is because I didn't see a value for the empty "ProcessID" column.
c00p
New
 
Posts: 6
Joined: Tue Oct 07, 2008 4:40 pm

Re: Help editing column layout

Postby alorbach » Fri Oct 10, 2008 1:43 pm

I forgot to mention that you need to change the default view id for your source to LEGACY, so the example here:
Code: Select all
$CFG['Sources']['Source1']['ViewID'] = "LEGACY";


The columns definition in config.php will be automatically mapped to ViewID LEGACY.
Please note that you could change the default and hardcoded views in includes/function_config.php, but I do not recommend to go this way. I would prefer to use the config.php approach, or go for the UserDB.

best regards,
Andre Lorbach
User avatar
alorbach
Site Admin
 
Posts: 1029
Joined: Thu Feb 13, 2003 11:55 am

Re: Help editing column layout

Postby c00p » Fri Oct 10, 2008 1:57 pm

I don't seem to have a convert.php script... I re-downloaded the latest stable (2.4) and don't see that script in there. I need to update the UserDB fields in config.php & run convert.php, correct? Do I need to pull a convert script from somewhere else?

[cdeville@fpslog001 ~]$ tar -ztf ./phplogcon-2.4.0.tar.gz */convert.php
tar: */convert.php: Not found in archive
tar: Error exit delayed from previous errors
[cdeville@fpslog001 ~]$ wget http://www.phplogcon.org/Downloads-req- ... d-36.phtml
*****Cut out wget schtuff*****
Saving to: `phplogcon-2.4.0.tar.gz.1'

100%[===============================================================================>] 267,929 173K/s in 1.5s

07:55:26 (173 KB/s) - `phplogcon-2.4.0.tar.gz.1' saved [267929/267929]

[cdeville@fpslog001 ~]$ tar -ztf ./phplogcon-2.4.0.tar.gz.1 */convert.php */install.php
phplogcon-2.4.0/src/install.php
tar: */convert.php: Not found in archive
tar: Error exit delayed from previous errors
c00p
New
 
Posts: 6
Joined: Tue Oct 07, 2008 4:40 pm

Re: Help editing column layout

Postby alorbach » Fri Oct 10, 2008 2:04 pm

Version 2.4.x stable does not has the UserDB System yet.
Please use the latest Version from the Beta branch which is 2.5.13 at the moment:
http://www.phplogcon.org/downloads

If you start fresh, you can enable and install the UserDB during installation of phpLogCon.

regards,
Andre
User avatar
alorbach
Site Admin
 
Posts: 1029
Joined: Thu Feb 13, 2003 11:55 am

Re: Help editing column layout

Postby c00p » Fri Oct 10, 2008 2:07 pm

ah, ok...it threw me off because the config.php had the userdb template there, just no convert script.
c00p
New
 
Posts: 6
Joined: Tue Oct 07, 2008 4:40 pm

Re: Help editing column layout

Postby alorbach » Fri Oct 10, 2008 2:20 pm

It was planned at the beginning and already in the config.php, but really finished with the start of the 2.5.x versions

Let me know if you got it working ;)
--
Andre
User avatar
alorbach
Site Admin
 
Posts: 1029
Joined: Thu Feb 13, 2003 11:55 am

Re: Help editing column layout

Postby c00p » Wed Oct 15, 2008 1:42 pm

Yep, I installed the latest beta and everything is working as expected now.

Thanks for all the help.
c00p
New
 
Posts: 6
Joined: Tue Oct 07, 2008 4:40 pm

Re: Help editing column layout

Postby rgerhards » Wed Oct 15, 2008 1:58 pm

Hi,

if you like phpLogCon, you could do the project a big favor and vote for it at

http://freshmeat.net/projects/phplogcon/

A good rating gives as more exposure and, being in its infancy, this is definitely something phpLogCon needs ;)

If you are already registered with freshmeat, it is a single click but even if not it is a quick 1-minute action. Would be great if you have this time.

Thanks,
Rainer
User avatar
rgerhards
Site Admin
 
Posts: 2196
Joined: Thu Feb 13, 2003 11:57 am

Google Ads



Return to General

Who is online

Users browsing this forum: No registered users and 0 guests

cron