Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 164494 - /usr/share/clamav/freshclam-sleep broken: `hostid` doesn't work on 64 bits
/usr/share/clamav/freshclam-sleep broken: `hostid` doesn't work on 64 bits
Product: Fedora
Classification: Fedora
Component: clamav (Show other bugs)
x86_64 Linux
medium Severity medium
: ---
: ---
Assigned To: Enrico Scholz
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2005-07-28 07:30 EDT by James Wilkinson
Modified: 2007-11-30 17:11 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2005-07-28 08:13:26 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description James Wilkinson 2005-07-28 07:30:22 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.10) Gecko/20050716

Description of problem:
The new clamav-update package puts a new clamav-update file in /etc/cron.d. This calls /usr/share/clamav/freshclam-sleep, a bash shellscript.

/usr/share/clamav/freshclam-sleep uses `hostid` to get a random time to sleep. On an AMD64 box:

[james@kendrick ~]$ hostid
[james@kendrick ~]$ echo $[ 0x`hostid`]

Not surprisingly, sleep doesn't like sleeping for negative seconds. Even if the number was positive, that's still an awfully long time to sleep.

Maybe line 26 of /usr/share/clamav/freshclam-sleep could be changed to use $RANDOM?


Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
[root@kendrick cron.d]# /usr/share/clamav/freshclam-sleep
sleep: invalid option -- 2
Try `sleep --help' for more information.

Additional info:
Comment 1 Enrico Scholz 2005-07-28 08:13:26 EDT
thx; should be solved in CVS


Note You need to log in before you can comment on or make changes to this bug.