omissions in stats system on SAIO docs

Bug #680188 reported by clayg
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Object Storage (swift)
Won't Fix
Low
Unassigned

Bug Description

You need to restart the proxy server for the log_local1 change to take effect (swift-init proxy reload)

IMHO, the proxy server config change and /var/log/swift directory creation should preceed restarting syslog-ng.

You could also wait to create the stats account until just before you create /etc/swift/log-processor.conf and you won't have to keep track of the account hash for quite so long...

Revision history for this message
clayg (clay-gerrard) wrote :

in my testing the cron entries required absolute paths, e.g.

0 * * * * <your-user-name> /usr/local/bin/swift-account-stats-logger /etc/swift/log-processor.conf

...it's been my experience that cron has no $PATH, YMMV

Revision history for this message
Soren Hansen (soren) wrote : Re: [Bug 680188] Re: omissions in stats system on SAIO docs

PATH is by default set to "/usr/bin:/bin" when running cron jobs.

You can change it in the crontab by specifying another value. Mind
you, you cannot do something like:
PATH=/usr/local/bin:$PATH

..since it does not do any variable expansion at all.

Revision history for this message
clayg (clay-gerrard) wrote :

thanks for the clarification Soren.

option a) use absolute paths
option b) set the PATH in the cron file i.e.
PATH=/usr/local/bin
0 * * * * <your-user-name> swift-account-stats-logger /etc/swift/log-processor.conf

clayg (clay-gerrard)
tags: added: stats
removed: docs
Revision history for this message
clayg (clay-gerrard) wrote :

the stats system reads the account databases - the stats in the account databases are only updated by the container-updater - on a saio, the cluster will normally be started with the "startmain" script - which doesn't start the container-updater - so if you want stats to work (at least the account storage stats piece) - you need to manually start the container-updater.

Something to that effect should probably be mentioned around "After running for a few hours" towards the end of the "Running the stats system on SAIO" section.

and of course:
swift-init container-updater start

Revision history for this message
Jay Payne (letterj) wrote :

Add to the documentation for setting up logging:

Once syslog-ng is set up the config can be tested by doing:

for local0
logger -p local0.info 'test syslog-ng config: somethingeasytogrepforfromlocal0'
or
for local1
logger -p local1.info 'test syslog-ng config: somethingeasytogrepforfromlocal1'

then

grep somethingeasytogrepforfromlocal0 <local0 log file destination>
or
grep somethingeasytogrepforfromlocal1 <local1 log file destination>

Changed in swift:
status: New → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.