USM Unified Slackware Package Manager

Here is a place for your projects which are not officially supported by the Porteus Team. For example: your own kernel patched with extra features; desktops not included in the standard ISO like Gnome; base modules that are different than the standard ISO, etc...
Bogomips
Full of knowledge
Full of knowledge
Posts: 2564
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: USM Unified Slackware Package Manager

Post#241 by Bogomips » 22 Aug 2014, 15:07

Code: Select all

guest@porteus:~$     awk -F= '/USMVERSION/{print$NF}' /etc/usm/usm.conf
3.1.4
guest@porteus:~$ ls -l /tmp/usm/usm-latest-0.0-noarch-1.txz
-rw-r--r-- 1 root root 61576 Aug  5 04:43 /tmp/usm/usm-latest-0.0-noarch-1.txz
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Re: USM Unified Slackware Package Manager

Post#242 by Ed_P » 22 Aug 2014, 15:23

fanthom wrote:besides: '-v' flag should be documented in the usm help.
So to should the '-u usm' option.
brokenman wrote:@Ed_P
It was already established in another thread that this is due to whiteout files. It is not finding your usm.conf file which is clearly there.
I thought the new initrd file in 3.0.1 was a fix for that. And how does that impact the updating of usm itself? Or, from another point, how do I upgrade to 3.1.5?

Code: Select all

root@porteus:/home/guest# usm -u usm
Downloading: vercheck.txt  DONE

/usr/share/usm/funcupdateDatabase: line 338: [: 140816: unary operator expected
No database updates were found.

/usr/share/usm/funcupdateDatabase: line 351: [: 140821: unary operator expected
You have the current USM version.

root@porteus:/home/guest# 
The update-usm.sh approach seems to be frowned upon. http://forum.porteus.org/viewtopic.php? ... 697#p24697
And I don't see .wh. files that should be effecting this.

Code: Select all

root@porteus:/home/guest# find /mnt/live/memory/changes/etc/usm/ -name .wh.*
/mnt/live/memory/changes/etc/usm/.wh.extra-deps.txt
root@porteus:/home/guest# find /mnt/live/memory/changes/ -name .wh.*
/mnt/live/memory/changes/.wh..wh.orph
/mnt/live/memory/changes/.wh..wh.plnk
/mnt/live/memory/changes/.wh..wh.aufs
/mnt/live/memory/changes/var/log/packages/.wh.usm-3.1.2-noarch-1
/mnt/live/memory/changes/var/log/packages/.wh.usm-3.1.0-noarch-2
/mnt/live/memory/changes/usr/lib64/.wh.libapm.so.1
and

Code: Select all

/mnt/live/memory/changes/etc/usm/.wh.extra-deps.txt
root@porteus:/home/guest# ls /tmp/usm/
root@porteus:/home/guest# 
Last edited by Ed_P on 22 Aug 2014, 15:47, edited 2 times in total.
Ed

User avatar
brokenman
Site Admin
Site Admin
Posts: 6105
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v4 all desktops
Location: Brazil

Re: USM Unified Slackware Package Manager

Post#243 by brokenman » 22 Aug 2014, 15:36

I have pushed the updates (for version check) to git. I also added extra info to: usm -i or usm info
Aug 5 04:43 /tmp/usm/usm-latest-0.0-noarch-1.txz
Any chance you have a .1 file in /tmp/usm? This bug was addressed in a previous version and all old usm*.txz packages are now removed before downloading of new packages. Will double check now.
So to should the '-u usm' option.
Will do.
I thought the new initrc file in 3.0.1 was a fix for that.
It does address the problem for people that don't already have the problem. All future users of changes=EXIT will not experience the problem. If you already have the problem in your savefile then the linuxrc fix will not help it.
And how does that impact the updating of usm itself?
It doesn't at all. I was referring to the hang you are having when updating databases.
Or, from another point, how do I upgrade to 3.1.5?
You can follow the manual update procedure explained in other threads. Please do this while booted into changes=/path/to/changes.dat and NOT changes=EXIT
Download the usm slackware package and install it using installpkg. I'm not so sure it will even fix your problem but I am hoping that booting with the changes= cheatcode and installing the slackware package will force the files to be seen.
How do i become super user?
Wear your underpants on the outside and put on a cape.

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Re: USM Unified Slackware Package Manager

Post#244 by Ed_P » 22 Aug 2014, 16:04

brokenman wrote:
Or, from another point, how do I upgrade to 3.1.5?
You can follow the manual update procedure explained in other threads. Please do this while booted into changes=/path/to/changes.dat and NOT changes=EXIT
Download the usm slackware package and intall it using installpkg. I'm not so sure it will even fix your problem but I am hoping that booting with the changes= cheatcode and installing the slackware package will force the files to be seen.
And we are cross posting. :( I'm updating my posting while you are adding yours. :o Have you seen my updates?

Something isn't right. I was able to upgrade to 3.1.4 after having problems upgrading to it initially when using 3.0.1, now I'm having problems again. I know how to remove .wh. files from my save.dat file I'm just not sure they are the problem. 98% of them are Firefox and Jave files.
Ed

User avatar
brokenman
Site Admin
Site Admin
Posts: 6105
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v4 all desktops
Location: Brazil

Re: USM Unified Slackware Package Manager

Post#245 by brokenman » 22 Aug 2014, 16:40

Have you seen my updates?
No. Please add EDIT: when updating previous posts so it is known that they were updated after the original post.
I was able to upgrade to 3.1.4 after having problems upgrading to it initially when using 3.0.1, now I'm having problems again.
Nothing has changed with the update procedure for quite a few versions. The procedure is quite simple. It removes any existing usm-latest-0.0-naorch-1.txz from storage. It downloads the latest usm-latest-0.0-naorch-1.txz file. It installs the usm-latest-0.0-naorch-1.txz file.
The update-usm.sh approach seems to be frowned upon.
I didn't mention anything about using this script. Please follow the instructions in my last post and see if it works. Be sure to boot into changes= and NOT changes=EXIT. Something is certainly screwed up in your changes file and it is near impossible for me to troubleshoot this. I don't know what you have and haven't deleted directly from the savefile and I have recommended not deleting files directly from this file. Delete them from the standard paths and the savefile will take care of itself.
How do i become super user?
Wear your underpants on the outside and put on a cape.

Bogomips
Full of knowledge
Full of knowledge
Posts: 2564
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: USM Unified Slackware Package Manager

Post#246 by Bogomips » 22 Aug 2014, 16:49

brokenman wrote:
Aug 5 04:43 /tmp/usm/usm-latest-0.0-noarch-1.txz
Any chance you have a .1 file in /tmp/usm? This bug was addressed in a previous version

Code: Select all

guest@porteus:~$ sudo find /tmp/usm -regex '.*\.1.*' -maxdepth 1
/tmp/usm/kate-4.10.5
/tmp/usm/at-spi2-atk-2.8.1-i486-1.xzm
/tmp/usm/vlc-qt-0.10.0-i486-1sl.txz
/tmp/usm/aaa_elflibs-14.1
/tmp/usm/at-spi2-atk-2.8.1-i486-1.txz
/tmp/usm/libao-1.1.0
/tmp/usm/vlc-2.1.4
/tmp/usm/libkcddb-4.10.5-i486-1.xzm
/tmp/usm/kde-baseapps-4.10.5
/tmp/usm/kdelibs-4.10.5-i486-2.xzm
/tmp/usm/vlc-2.1.5
/tmp/usm/vlc-2.1.2
brokenman wrote:and all old usm*.txz packages are now removed before downloading of new packages.
Another possibility: old usm*.txz packages removed and old file downloaded?
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

User avatar
brokenman
Site Admin
Site Admin
Posts: 6105
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v4 all desktops
Location: Brazil

Re: USM Unified Slackware Package Manager

Post#247 by brokenman » 22 Aug 2014, 17:08

Another possibility: old usm*.txz packages removed and old file downloaded.
I checked the server file before releasing it. The new one replaces the old one on the server. In your nonstandard setup please give output of: md5sum /etc/usm/usm.conf p10/Por/usm.conf
Essentially I need more people to report if they are having problems with this.
How do i become super user?
Wear your underpants on the outside and put on a cape.

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Re: USM Unified Slackware Package Manager

Post#248 by Ed_P » 22 Aug 2014, 18:39

Have you looked at this script?

Code: Select all

Downloading: vercheck.txt  DONE

/usr/share/usm/funcupdateDatabase: line 338: [: 140816: unary operator expected
No database updates were found.

/usr/share/usm/funcupdateDatabase: line 351: [: 140821: unary operator expected
You have the current USM version.

root@porteus:/home/guest# 
=EDIT=

Code: Select all

root@porteus:/home/guest# ls /tmp/usm/vercheck.txt
/bin/ls: cannot access /tmp/usm/vercheck.txt: No such file or directory
root@porteus:/home/guest# find vercheck.txt
find: `vercheck.txt': No such file or directory
root@porteus:/home/guest# 
=EDIT=
FWIW

Code: Select all

root@porteus:/home/guest# md5sum /etc/usm/usm.conf p10/Por/usm.conf
9a9ccd2cdefb649e6c4801814c981bd8  /etc/usm/usm.conf
md5sum: p10/Por/usm.conf: No such file or directory
root@porteus:/home/guest# 
=EDIT=
FWIW

Code: Select all

download $UPDLINK/configs/vercheck.txt $TMPDIR

echo
[ ! -e $TMPDIR/vercheck.txt ] && fatality "$SCRIPT $FUNCNAME $LINENO" "`gettext "Could not download file:"`" "vercheck.txt"
RDBVER=`awk -F"=" /DBVER/'{print$NF}' $TMPDIR/vercheck.txt`
RUSMVER=`awk -F"=" /USMVER/'{print$NF}' $TMPDIR/vercheck.txt`

echo RDBVER=$RDBVER
echo DBVER=$DBVER
echo ls $TMPDIR
ls $TMPDIR
echo

if [ $RDBVER -gt $DBVER ]; then

Code: Select all

root@porteus:/home/guest# cp -u -v funcupdateDatabase /usr/share/usm
‘funcupdateDatabase’ -> ‘/usr/share/usm/funcupdateDatabase’
root@porteus:/home/guest# usm -u usm
Downloading: vercheck.txt  DONE

RDBVER=140816
DBVER=
ls /tmp/usm.P6vL9R
filelist	   sbo-categories.tmp  searchType  vercheck.txt  welcome.bak
help-pkgtools.tmp  sbocategs	       term1.tmp   welcome

/usr/share/usm/funcupdateDatabase: line 344: [: 140816: unary operator expected
No database updates were found.

/usr/share/usm/funcupdateDatabase: line 357: [: 140821: unary operator expected
You have the current USM version.

root@porteus:/home/guest# 
Ed

Bogomips
Full of knowledge
Full of knowledge
Posts: 2564
Joined: 25 Jun 2014, 15:21
Distribution: 3.2.2 Cinnamon & KDE5
Location: London

Re: USM Unified Slackware Package Manager

Post#249 by Bogomips » 22 Aug 2014, 19:57

brokenman wrote:In your nonstandard setup please give output of: md5sum /etc/usm/usm.conf p10/Por/usm.conf
Have standard setup, except for bind on /var/usm and /tmp/usm.

Code: Select all

guest@porteus:~$ md5sum p10/Por/usm.conf
9700327a8b316ad2897b941d9367856b  p10/Por/usm.conf
is irrrelevant because

Code: Select all

guest@porteus:~$     awk -F= '/DBDIR/{print$NF}' p10/Por/usm.conf
/home/guest/p10/Por/var/usm
# The mirror files are stored in ${DBDIR}/mirrors-distro.txt
guest@porteus:~$     awk -F= '/STORAGE/{print$NF}' p10/Por/usm.conf
/home/guest/p10/Por/tmp/usm
brokenman wrote:please give output of: md5sum /etc/usm/usm.conf

Code: Select all

guest@porteus:~$ md5sum /etc/usm/usm.conf
829c2664e6e5de136f03e70cd7c18b6c  /etc/usm/usm.conf
However what is of interest, is it seems the config file version number has remained unchanged, bearing in mind the dates of the files:

Code: Select all

guest@porteus:~$     awk -F= '/USMVER/{print$NF}' /etc/usm/usm.conf
3.1.4
140816
guest@porteus:~$ ls -l p10/Por/usm.conf
-rw-r--r-- 1 root root 3187 Aug 11 15:17 p10/Por/usm.conf
guest@porteus:~$     awk -F= '/USMVER/{print$NF}' p10/Por/usm.conf
3.1.4
140804
Don't see why version has to be in config file, and why an include file to hold the version number isn't used.
Linux porteus 4.4.0-porteus #3 SMP PREEMPT Sat Jan 23 07:01:55 UTC 2016 i686 AMD Sempron(tm) 140 Processor AuthenticAMD GNU/Linux
NVIDIA Corporation C61 [GeForce 6150SE nForce 430] (rev a2) MemTotal: 901760 kB MemFree: 66752 kB

User avatar
brokenman
Site Admin
Site Admin
Posts: 6105
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v4 all desktops
Location: Brazil

Re: USM Unified Slackware Package Manager

Post#250 by brokenman » 22 Aug 2014, 20:57

@Bogomips
In an earlier post you gave the output:

Code: Select all

root@porteus:/home/guest# diff p10/Por/usm.conf /etc/usm
15c15
< DBDIR=/home/guest/p10/Por/var/usm
---
> DBDIR=/var/usm
23c23
< STORAGE=/home/guest/p10/Por/tmp/usm
---
> STORAGE=/tmp/usm
This is odd. Two config files. This is where I am confused.

When I bind mount the config directory somewhere and diff the usm.conf file there is no difference (expected behaviour) since the paths are bound.
root@porteus:/# mount --bind /etc/usm/ /mnt/bound/
root@porteus:/# diff /mnt/bound/usm.conf /etc/usm/usm.conf

If I ask for the output of a file in a certain path, please follow the instructions to the letter. Once again /etc/usm/usm.conf is a hard coded value so USM is not even going to look at your p10/Por directory. You can bind it for whatever purpose you like but USM won't care about your bind.

Here is the md5sum of the unchanged v3.1.5 usm.conf: 642fd67595b728e2a7f2e96ab09e989d

@Ed_P
Have you looked at this script?
Yes. funcupdateDatabase is looking for a file that isn't there for whatever reason. It is expecting a number (the database version) which is not returning a value, hence the error.
root@porteus:/home/guest# ls /tmp/usm/vercheck.txt
/bin/ls: cannot access /tmp/usm/vercheck.txt: No such file or directory
Expected output.
root@porteus:/home/guest# md5sum /etc/usm/usm.conf p10/Por/usm.conf
9a9ccd2cdefb649e6c4801814c981bd8 /etc/usm/usm.conf
Apart from including p10/Por/usm.conf (which is a path only on Bogomips computer) the md5sum shown is not that of the untouched v3.1.5 usm.conf file.

I am not sure what you mean by your next code tag. It shows code from USM. Looks fine.
root@porteus:/home/guest# cp -u -v funcupdateDatabase /usr/share/usm
‘funcupdateDatabase’ -> ‘/usr/share/usm/funcupdateDatabase’
root@porteus:/home/guest# usm -u usm
Downloading: vercheck.txt DONE

RDBVER=140816
DBVER=
Again I don't know why you have copied a file from /home/guest into /usr/share/usm. Means nothing to me. Also the next output of RDBVER=140816 and DBVER= ... where is this from? It is certainly incorrect. Did you even try my suggestion to fix your problem? Until you start a new clean savefile (without running any of your custom cleanup scripts on it) and test USM again I am not really interested in any of your output. I simply can not troubleshoot a problem that I (nor anyone else) can not reproduce. It is just noise in this thread. I understand you want to troubleshoot this, but you are not showing any sign of following suggestions and I can not reproduce this problem which may be because of your current changes file.
How do i become super user?
Wear your underpants on the outside and put on a cape.

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Re: USM Unified Slackware Package Manager

Post#251 by Ed_P » 22 Aug 2014, 21:17

brokenman wrote:I am not sure what you mean by your next code tag. It shows code from USM. Looks fine.
It shows the additional code I added to the script to help debug the problem.
root@porteus:/home/guest# cp -u -v funcupdateDatabase /usr/share/usm
‘funcupdateDatabase’ -> ‘/usr/share/usm/funcupdateDatabase’
root@porteus:/home/guest# usm -u usm
Downloading: vercheck.txt DONE

RDBVER=140816
DBVER=
Again I don't know why you have copied a file from /home/guest into /usr/share/usm. Means nothing to me. Also the next output of RDBVER=140816 and DBVER= ... where is this from?
When I find the file in guest mode with spaceFM and edit it with LeafPad I can not save it in /usr/share/usm/ directory, so I save it in /home/guest/ then using root mode in LXTerminal I copy it to where it belongs. The displays from the code I added show why the lines in error in your script are failing.
Ed

User avatar
brokenman
Site Admin
Site Admin
Posts: 6105
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v4 all desktops
Location: Brazil

Re: USM Unified Slackware Package Manager

Post#252 by brokenman » 22 Aug 2014, 21:34

Ok. Try not to add anything uncommented to a code output. It looks like output from a console otherwise. Also it would help if you actually explain what you are doing to get the output instead of just putting 'FWIW'. Now that you have said what's going on I can see the progression and as I stated, the script is choking because it is expecting to get a DBVER= variable and it is not getting one. This leads us back to step one and my previous post.
How do i become super user?
Wear your underpants on the outside and put on a cape.

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Re: USM Unified Slackware Package Manager

Post#253 by Ed_P » 23 Aug 2014, 03:22

brokenman wrote:the script is choking because it is expecting to get a DBVER= variable and it is not getting one. This leads us back to step one and my previous post.
I see no code in funcupdateDatabase that sets the DBVER variable. The vercheck.txt file that gets downloaded contains a value for it.

Code: Select all

cat /tmp/usm.pvL4eW/vercheck.txt
USMVER=140821
DBVER=140816
And the script sets the RDBVER and RUSMVER variables from them but I don't see the DBVER variable being set.
Ed

User avatar
brokenman
Site Admin
Site Admin
Posts: 6105
Joined: 27 Dec 2010, 03:50
Distribution: Porteus v4 all desktops
Location: Brazil

Re: USM Unified Slackware Package Manager

Post#254 by brokenman » 23 Aug 2014, 04:20

I see no code in funcupdateDatabase that sets the DBVER variable.
I'm not at all surprised.

Look. You haven't followed any of my instructions. You refuse to take any advice to resolve your problem. If the problem was related to the code not setting these variables then NOBODY would be able to update. Simple as that. I will repeat what I said in my above post, and until this is done will ignore your posts.

Until you start a new clean savefile (without running any of your custom cleanup scripts on it) and test USM again I am not really interested in any of your output.

Tonight I have wasted a lot of valuable time testing with the changes=EXIT cheatcode and simply can NOT reproduce your problem. C'mon .... Really .... you struggled to find the help dialog for the 'ls' command and now you are pulling apart the USM code and showing me what is wrong? :wall: I am a patient man, but you have pushed me to the limit.

The DBVER variable is clearly set in the usm.conf file that you have shown here numerous times. It is the the part that says DBVER=XXXX and it is sourced in the /usr/bin/usm file.
How do i become super user?
Wear your underpants on the outside and put on a cape.

User avatar
Ed_P
Contributor
Contributor
Posts: 8341
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

Re: USM Unified Slackware Package Manager

Post#255 by Ed_P » 23 Aug 2014, 06:08

brokenman wrote:Until you start a new clean savefile (without running any of your custom cleanup scripts on it) and test USM again I am not really interested in any of your output.
I am not going to delete everything and start fresh everytime you create a new USM or a minor Porteus version. I shouldn't have to nor should anyone else. This isn't Windows, I shouldn't have to always reboot or reinstall the OS to fix problems.
you struggled to find the help dialog for the 'ls' command
I did not. I pointed out an error in your perfect code, '-help' is not an invalid 'e' or whatever the error msg said. It's an invalid 'option'.

BTW I'll let you find the error in this /usr/share/usm/<README> file's line #2

Code: Select all

# Copyright (C) 20013-2020 Jay Flood
The DBVER variable is clearly set in the usm.conf file that you have shown here numerous times. It is the the part that says DBVER=XXXX and it is sourced in the /usr/bin/usm file.
Yup, and I have a usm.conf file in my /etc/usm/ directory, so why isn't it being read and an error msg indicating why it isn't?

Code: Select all

guest@porteus:~$ ls -l /etc/usm/*.conf
-rw-r--r-- 1 root root  947 Aug  4 19:11 /etc/usm/files.conf
-rw-r--r-- 1 root root 3137 Aug 17 23:02 /etc/usm/usm.conf

Code: Select all

# usm.conf - Configuration for Unified Slackware Manager (usm)
#

# Resolve dependencies for all packages
# Set this to true or false (never uncomment this)
RESOLVE=true

# The automatice update check that is made when internet
# is accessed. This update check doubles as a check that
# you have internet access before downloading packages.
# Set to false to disable update check.
AUTOCHECK=true

# Storage of database files (e.g PACKAGES.TXT)
DBDIR=/var/usm
:
etc.
Ed

Post Reply