Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fsck: Fix path for awk. #73

Merged
merged 2 commits into from
Jun 11, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions manifests/fsck.pp
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,12 @@
hour => fqdn_rand(24,'cvmfs'),
minute => fqdn_rand(60,'cvmfs'),
weekday => fqdn_rand(7,'cvmfs'),
command => '/usr/local/sbin/cvmfs_fsck_cron.sh -i 86400 2>&1 | /bin/awk \'{ print strftime("\%Y-\%m-\%d \%H:\%M:\%S"), $0; }\' >> /var/log/cvmfs_fsck.log',
command => '/usr/local/sbin/cvmfs_fsck_cron.sh -i 86400 2>&1 | /usr/bin/awk \'{ print strftime("\%Y-\%m-\%d \%H:\%M:\%S"), $0; }\' >> /var/log/cvmfs_fsck.log',
require => [File['/usr/local/sbin/cvmfs_fsck_cron.sh'],Package[$tmpcleaning_pkg]],
}
if $onreboot {
cron{'cvmfs_fsck_on_reboot':
command => '/usr/local/sbin/cvmfs_fsck_cron.sh -i 0 2>&1 | /bin/awk \'{ print strftime("\%Y-\%m-\%d \%H:\%M:\%S"), $0; }\' >> /var/log/cvmfs_fsck.log',
command => '/usr/local/sbin/cvmfs_fsck_cron.sh -i 0 2>&1 | /usr/bin/awk \'{ print strftime("\%Y-\%m-\%d \%H:\%M:\%S"), $0; }\' >> /var/log/cvmfs_fsck.log',
special => 'reboot',
require => File['/usr/local/sbin/cvmfs_fsck_cron.sh'],
}
Expand Down
2 changes: 1 addition & 1 deletion templates/cvmfs_fsck_cron.sh.erb
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,6 @@ UPTIME=$(/usr/bin/awk -F'[ .]' '{print $1}' /proc/uptime)
# Only run if up for more than one day. If you want sooner enable the
# on reboot cron job.
if [ $UPTIME -gt $IGNORE ] && [ -d <%= @cvmfs_cache_base %>/shared ] ; then
/bin/nice /usr/bin/cvmfs_fsck <%= @options %> <%= @cvmfs_cache_base %>/shared
/usr/bin/nice /usr/bin/cvmfs_fsck <%= @options %> <%= @cvmfs_cache_base %>/shared
fi