Tried to navigate to the System->Software Update page, and got an error page. I am running the last published testing channel release (3.9.1-16 if I recall). Kernel is 4.12.4-1.el7.elrepo.x86_64
Detailed step by step instructions to reproduce the problem
Open Rockstor web ui.
Attempt to navigate to the Software Update page.
Get pink screen.
Web-UI screenshot
Houston, we’ve had a problem.
Unable to check update due to a system error: Error running a command. cmd = /usr/bin/yum changelog None rockstor. rc = 1. stdout = [‘Loaded plugins: changelog, fastestmirror, priorities’, ‘’]. stderr = [’’, ‘’, ‘Argument – None – is not “all”, a positive number or a date’, ‘’]
Error Traceback provided on the Web-UI
Traceback (most recent call last):
File "/opt/rockstor/src/rockstor/storageadmin/views/command.py", line 195, in post
return Response(update_check(subscription=subo))
File "/opt/rockstor/src/rockstor/system/pkg_mgmt.py", line 163, in update_check
o, e, rc = run_command([YUM, 'changelog', date, pkg])
File "/opt/rockstor/src/rockstor/system/osi.py", line 121, in run_command
raise CommandException(cmd, out, err, rc)
CommandException: Error running a command. cmd = /usr/bin/yum changelog None rockstor. rc = 1. stdout = ['Loaded plugins: changelog, fastestmirror, priorities', '']. stderr = ['', '', 'Argument -- None -- is not "all", a positive number or a date', '']
@kupan787 Hello again.
So this is a strange one. I’ve tested on three different testing channel installs here and have not been able to reproduce the issue; the testing channel is now a bit outdated by the stable channel but still, I didn’t see this issue. There has been an update in this area on the stable channel but given I didn’t see it here is odd. From your log excerpt it looks like ‘date’ is ending up as ‘None’ ie:
run_command([YUM, 'changelog', date, pkg])
ends up having the following values as exposed by the CommandException thrown by run_command:
cmd = /usr/bin/yum changelog None rockstor
with the understandable result of:
‘Argument – None – is not “all”, a positive number or a date’
The variable ‘date’ is returned by the following code:
But this will look a little different on a testing channel install as the following pr and it’s associated changes have since been made, but not to address the issue you have reported (date as None). Your installed version of this file is to be found at:
/opt/rockstor/src/rockstor/system/pkg_mgmt.py
and the only changes that have been made to pkg stuff are detailed in the associated pull request:
Could you paste the output of the following commands:
yum info rockstor
and
yum info installed -v rockstor
I did test the indicated patch as applied to the then testing channel version and it did function as intended so it may be that whatever is causing you problem on your system will be fixed by the changes indicated in that pull request. I suspect that is your fix, but I’m not clear on why I don’t see the same issue here.
Sorry I can’t look into this any further as I’m pretty involved in a couple of pending pr’s that I need to ‘bring home’ but let us know how you get on with this one and as always thanks for reporting your findings.
[root@rocknas ~]# yum info rockstor
Loaded plugins: changelog, fastestmirror, priorities
Loading mirror speeds from cached hostfile
* base: mirror.fileplanet.com
* elrepo: repos.lax-noc.com
* epel: mirror.sfo12.us.leaseweb.net
* extras: mirror.fileplanet.com
* ius: mirrors.kernel.org
* updates: mirror.fileplanet.com
Installed Packages
Name : rockstor
Arch : x86_64
Version : 3.9.1
Release : 16
Size : 85 M
Repo : installed
From repo : Rockstor-Testing
Summary : RockStor -- Store Smartly
License : GPL
Description : RockStor -- Store Smartly
[root@rocknas ~]# yum info installed -v rockstor
Loading "changelog" plugin
Loading "fastestmirror" plugin
Loading "priorities" plugin
Config time: 0.026
Yum version: 3.4.3
rpmdb time: 0.000
Installed Packages
Name : rockstor
Arch : x86_64
Version : 3.9.1
Release : 16
Size : 85 M
Repo : installed
From repo : Rockstor-Testing
Committer : Suman Chakravartula <suman@rockstor.com>
Committime : Sun Jul 2 05:00:00 2017
Buildtime : Sun Oct 22 12:36:36 2017
Install time: Mon Oct 23 04:11:46 2017
Installed by: System <unset>
Changed by : root <root>
Summary : RockStor -- Store Smartly
License : GPL
Description : RockStor -- Store Smartly
Is there a way to manually apply this? Or would I be best to just wait for the new method that @suman is working on to update testing users?
Not a problem. This isn’t a huge issue at this time, as there aren’t updates to apply. I only happened to stumble on to it because I was clicking around in the UI.
Yes: you can either edit (ie via nano) the previously indicated file so that the “def rpm_build_info(pkg):” section reads as I posted earlier or you could follow the instructions in How to apply a patch to aid in development using the following patch url:
if all goes well then you should receive the following reply from the patch command indicated in those instructions:
patching file src/rockstor/system/pkg_mgmt.py
I have just tested this patch on a 3.9.1-16 install here and all was well, although that install didn’t exhibit your issue in the first place.
In either case it may be necessary to restart the rockstor service there after via:
systemctl restart rockstor
for the changes to take effect, as there is a chance that you system will be ‘holding onto’ the previous version of the file if it was active at the time.
That depends on how happy you are taking the risks indicated in the above wiki post. You will always be able to update via ‘yum update’, assuming that the last testing channel update is delivered that way; which is the plan I believe. But it may be of more use overall to know if this patch works in your setting; just in case others run into the same thing. See how you feel after reading the indicated wiki and take it from there. If it fails you can always restore the backup version of the file the instructions talk you though making.
So I did the following, got the patching file message. However, now I get a new error
Houston, we’ve had a problem.
Unable to check update due to a system error: Error running a command. cmd = /usr/bin/yum changelog 2017-Oct-23 rockstor. rc = 1. stdout = [‘Loaded plugins: changelog, fastestmirror, priorities’, ‘’]. stderr = [‘Traceback (most recent call last):’, ’ File “/usr/bin/yum”, line 29, in ‘, ’ yummain.user_main(sys.argv[1:], exit_code=True)’, ’ File “/usr/share/yum-cli/yummain.py”, line 370, in user_main’, ’ errcode = main(args)’, ’ File “/usr/share/yum-cli/yummain.py”, line 179, in main’, ’ result, resultmsgs = base.doCommands()’, ’ File “/usr/share/yum-cli/cli.py”, line 583, in doCommands’, ’ return self.yum_cli_commands[self.basecmd].doCommand(self, self.basecmd, self.extcmds)’, ’ File “/usr/lib/yum-plugins/changelog.py”, line 215, in doCommand’, " if self._since_dto == dateutil_parser.parse(‘garbage’, fuzzy=True):", ’ File “/usr/lib/python2.7/site-packages/dateutil/parser.py”, line 1182, in parse’, ’ return DEFAULTPARSER.parse(timestr, **kwargs)’, ’ File “/usr/lib/python2.7/site-packages/dateutil/parser.py”, line 562, in parse’, ’ raise ValueError(“String does not contain a date.”)’, ‘ValueError: String does not contain a date.’, ‘’]
Traceback (most recent call last):
File “/opt/rockstor/src/rockstor/storageadmin/views/command.py”, line 195, in post
return Response(update_check(subscription=subo))
File “/opt/rockstor/src/rockstor/system/pkg_mgmt.py”, line 164, in update_check
o, e, rc = run_command([YUM, ‘changelog’, date, pkg])
File “/opt/rockstor/src/rockstor/system/osi.py”, line 121, in run_command
raise CommandException(cmd, out, err, rc)
CommandException: Error running a command. cmd = /usr/bin/yum changelog 2017-Oct-23 rockstor. rc = 1. stdout = [‘Loaded plugins: changelog, fastestmirror, priorities’, ‘’]. stderr = [‘Traceback (most recent call last):’, ’ File “/usr/bin/yum”, line 29, in ‘, ’ yummain.user_main(sys.argv[1:], exit_code=True)’, ’ File “/usr/share/yum-cli/yummain.py”, line 370, in user_main’, ’ errcode = main(args)’, ’ File “/usr/share/yum-cli/yummain.py”, line 179, in main’, ’ result, resultmsgs = base.doCommands()’, ’ File “/usr/share/yum-cli/cli.py”, line 583, in doCommands’, ’ return self.yum_cli_commands[self.basecmd].doCommand(self, self.basecmd, self.extcmds)’, ’ File “/usr/lib/yum-plugins/changelog.py”, line 215, in doCommand’, " if self._since_dto == dateutil_parser.parse(‘garbage’, fuzzy=True):", ’ File “/usr/lib/python2.7/site-packages/dateutil/parser.py”, line 1182, in parse’, ’ return DEFAULTPARSER.parse(timestr, **kwargs)’, ’ File “/usr/lib/python2.7/site-packages/dateutil/parser.py”, line 562, in parse’, ’ raise ValueError(“String does not contain a date.”)’, ‘ValueError: String does not contain a date.’, ‘’]