No List of Package Database Installed in /var/log/packages - Slackware 13.37
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
No List of Package Database Installed in /var/log/packages - Slackware 13.37
Hi,
I managed to install Slackware 13.37, and later on wanted to remove a package when I realized nothing is showing up in `pkgtool' view/remove menus. As a matter of fact, there is nothing in /var/log/packages to begin with. The only package available is a library I installed after Slackware installation (DVD). I selected individual packages -- a painstaking process -- during my setup installation, and I was hoping I could keep the list for future reference but alas, there is nothing there now.
I don't know how that happened but I opted to use LVM to manage my devices and placed /var/log and /var, each, in their own respective logical volume. I do not know if that somehow caused problems in terms of setup installation not being able to write to /var/log.
Is there anyway I can get the list of installed packages now? Or is there a program that can scan my system and generate a list of installed packages? This is just terrible.
The list of packages might be in the /var/log/packages directory on your root partition, but invisible since your LVM volumes are mounted on top.
You might want to login as root, runlevel 1 and check.
If everything is there, copy the contents to a temporary location (like /root/var/...) and then login again normally with your logical volumes mounted and move everything over.
I think we can do something but I don't have much script-fu to do it myself.
-First of all, Every file in the system can be find part of which package easily (by grepping manifest.gz or using slackpkg file-search)
-Using first information, we can get some command combo to grep manifest.gz file by file, it will take some time but it is a sure way to get a list of insttaled packages with apsense of package logs.
The list of packages might be in the /var/log/packages directory on your root partition, but invisible since your LVM volumes are mounted on top.
You might want to login as root, runlevel 1 and check.
If everything is there, copy the contents to a temporary location (like /root/var/...) and then login again normally with your logical volumes mounted and move everything over.
I did `init 1' but inspecting /var/log appears to show an old directory structure with nothing in the packages/. I don't know what happened; maybe I formatted /var/log before /var in Slackware installation setup's TARGET but not sure in what order or procedure does the `setup' program executes commands, i.e. does it only format when partitions are assigned a mount point in TARGET sub-menu and then once all are done (displays the content of /etc/fstab), it performs the actual mount command, or does it do it individually after each filesystem formatting!
What should the order of formatting (in setup's TARGET) be if one decides to put /var and /var/log on different LV's?
I think we can do something but I don't have much script-fu to do it myself.
-First of all, Every file in the system can be find part of which package easily (by grepping manifest.gz or using slackpkg file-search)
-Using first information, we can get some command combo to grep manifest.gz file by file, it will take some time but it is a sure way to get a list of insttaled packages with apsense of package logs.
Thank you, but I'm having a hard time seeing how that can be any help. I updated slackpkg which apparently retrieved list of all the latest packages for 13.37, then executed your command with some modifications because I don't think it's correct:
If I simply execute the `find' command, it doesn't list any "installed" (or for that matter a string "[ installed ]") but merely "[uninstalled]" list. I don't think this list is any help, because I see list of packages which include many that I did not install and many that I did install. So I'm assuming it's a comprehensive list of all packages -- 1118 of them.
as far as I know, the slackware installer formats partitions (and mounts them after, asking the mountpoint) *before* any actual file is copied/installed/created in the target, so you should be safe following the standard procedure.
Thank you, but I'm having a hard time seeing how that can be any help. I updated slackpkg which apparently retrieved list of all the latest packages for 13.37, then executed your command with some modifications because I don't think it's correct:
If I simply execute the `find' command, it doesn't list any "installed" (or for that matter a string "[ installed ]") but merely "[uninstalled]" list. I don't think this list is any help, because I see list of packages which include many that I did not install and many that I did install. So I'm assuming it's a comprehensive list of all packages -- 1118 of them.
It has duplicates. There's a reason I put sort | uniq there.
as far as I know, the slackware installer formats partitions (and mounts them after, asking the mountpoint) *before* any actual file is copied/installed/created in the target, so you should be safe following the standard procedure.
Correct, but... If you create new partitions after installation (LVM or not, second drive for instance), then you will have to take care to copy / move all files already there.
as far as I know, the slackware installer formats partitions (and mounts them after, asking the mountpoint) *before* any actual file is copied/installed/created in the target, so you should be safe following the standard procedure.
I see, but if I can vaguely remember, when I tried to select a mounting point and format a LV for /var/log, the installation crapped out, spewed bunch of errors that basically it cannot write to /var/log/something, and ultimately exited the setup installation and back to the prompt line. I ran the `setup' again, this time, formatted (and I assume mounting is performed after individual formatting) /var first, then /var/log which produced no error message.
I could be wrong, maybe I formatted/created mounting point for /var first, then /var/log which caused those errors, nonetheless, after the second try, it did work and I managed to install everything without any problem. Note that I did not start selecting or installing any packages prior to getting everything set in ADDSWAP and TARGET.
It has duplicates. There's a reason I put sort | uniq there.
Right, but that's not an issue here. The list I get from `slackpkg' only lists all the uninstalled packages, and it really includes everything. I'm presuming that since it cannot find any package list installed on my system, it lists "all" packages which is no use in this case.
Correct, but... If you create new partitions after installation (LVM or not, second drive for instance), then you will have to take care to copy / move all files already there.
No new partition or LV created after the installation, only extended /usr afterward without any problem. I didn't touch /var or /var/log LV's.
Right, but that's not an issue here. The list I get from `slackpkg' only lists all the uninstalled packages, and it really includes everything. I'm presuming that since it cannot find any package list installed on my system, it lists "all" packages which is no use in this case.
actually it will say uninstalled as it uses log/packages for checking if package is installed or not. ANd because we check if a file already existing in the system, it is usure that list is installed packaged.
actually it will say uninstalled as it uses log/packages for checking if package is installed or not. ANd because we check if a file already existing in the system, it is usure that list is installed packaged.
Right, as I guessed, it performs some comparison between what has been installed by scanning /var/log/packages, but since mine is empty, it makes a full list. *sigh*
Right, as I guessed, it performs some comparison between what has been installed by scanning /var/log/packages, but since mine is empty, it makes a full list. *sigh*
I see, but if I can vaguely remember, when I tried to select a mounting point and format a LV for /var/log, the installation crapped out, spewed bunch of errors that basically it cannot write to /var/log/something, and ultimately exited the setup installation and back to the prompt line. I ran the `setup' again, this time, formatted (and I assume mounting is performed after individual formatting) /var first, then /var/log which produced no error message.
I could be wrong, maybe I formatted/created mounting point for /var first, then /var/log which caused those errors, nonetheless, after the second try, it did work and I managed to install everything without any problem. Note that I did not start selecting or installing any packages prior to getting everything set in ADDSWAP and TARGET.
When the setup exited/crashed the first time (I guess because of playing with partitions after having started it), probably it has left the running OS of the installer in an inconsistent state.
When this happens, I think it's advisable to shutdown and restart the installation.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.