LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Mandriva (https://www.linuxquestions.org/questions/mandriva-30/)
-   -   Be careful when removing orphan packages (https://www.linuxquestions.org/questions/mandriva-30/be-careful-when-removing-orphan-packages-678619/)

dickgregory 10-23-2008 02:50 PM

Be careful when removing orphan packages
 
So far I really like Mandriva 2009. I had a minor issue with my NFS stuff trying to mount before the network was up.

The only other issue I had was related to the orphan removal. Here's the scenario:

I installed the default 2009 / KDE4 and finished setting up the basic system. Then I installed task-gnome.

I got the message that there were orphans, so I went to a command line and entered the suggested orphan removal urpme command.

Like a fool, I didn't look closely at the removal list. I just accepted it. :o

Guess what. It removed KDE. NOT GOOD !!!

No, I did not uncheck task-kde.

Otherwise an excellent product. I just won't use orphan removal until it is stable and robust.

I just wanted to warn others that might avoid such a mishap that might make them decide against using this distro.

GlennsPref 10-23-2008 05:18 PM

Hi, thanks for the headsup.

I also used the orphan tool. It's a lot better that rpm-orphan, or deb-orphan used to be.

Aside from that, the urpmi skip list is handy to stop installing stuff you don't want.

Smart also has a version lock facility, so you can keep what you want and upgrade the rest.

You always have to watch the output of those programs. You, the user are the last line of defense.

I generally, copy any list, and then wade through it manually removing the packages, and watching for any deps that might break the system.

to re-install kde4, using urpmi

urpmi kdebase4-runtime kdebase4-workspace

and any deps (when on initial install this equates to approx 100 packages)

A nice way to check what is missing...

rpm -Va | grep miss

Will list missing libs (this might take a while to complete), you may get back to your kde setup this way.

Another good cleanup utility is fslint, but for all other files (and copies), not the rpm database.

Regards, Glenn

dickgregory 10-23-2008 08:06 PM

FYI, my original post was meant to be informational, not a request for help. I had no problem getting KDE back. I just re-installed task_kde and everything is back to normal. It was only an minor inconvenience for me, but for a newbie it might have been a show stopper.

GlennsPref 10-24-2008 04:41 AM

I did say thanks! ;)

I guess it was rhetorical.

regards, Glenn

phidor 11-04-2008 02:02 AM

Hi Glenn or any others...

When I tried upgrading Mandriva 2009 using urpmi, these two files:
kdebase4-workspace4.1.2 release 13.3
oxygen-icon-theme4.1.2 release 3.2
will both not download (they freeze in the last one or two seconds)
- is this, maybe, because of orphans I have removed?!

Phidor.

GlennsPref 11-04-2008 04:05 AM

Hi, I don't think it is. phidor.

They are quite large packages, oxygen-icon-theme is about 30Mb.

I would persist, retry.

if you're using cli urpmi try thr --noclean switch.

After the install the package may be found /var/cache/urpmi/rpms

I know with the smart package manager you can retry and it will keep adding to the cache until you stop trying or the job is completed.

It is not because of removed orphans.

Cheers, Glenn

phidor 11-04-2008 02:43 PM

The --noclean CLI option worked perfectly - for both packages. Although I did not want either of them 'twas immensely satisfying beating the problem - the goal being to understand what I am doing. In this regard thank you Glenn, your help is genuinely valued. I love Linux and the human help in the Linux community is the most wonderful part of it!

Cheers, Phidor.

GlennsPref 11-04-2008 07:41 PM

Phidor, one more thing, you can make your own rpm database on your system, copy all rpm's from

/var/cache/urpmi/rpms to a safe place for future use.

then when you have a few there, run genhdlist2 on the directory and it will generate the md5sum, hdlist, etc and you will be able to add it to your Mandriva Local rpm database.

This can save you having to download the same package twice. Especially the larger ones like you mentioned above, approx. 50Mb.

Cheers, Glenn

ps. If you want kde4.1.2, you'll need both of those.

phidor 11-04-2008 08:09 PM

Thanks Glenn. I went to /var/cache/urpmi/rpms and did this: [root@localhost rpms]# genhdlist2 ./
whence this stuff came up on the screen:

adding 2 new rpms not available in existing hdlist
replacing .//media_info/hdlist.cz with hdlist.cz.tmp
replacing .//media_info/synthesis.hdlist.cz with synthesis.hdlist.cz.tmp
updating .//media_info/MD5SUM

and I discovered a new folder in /var/cache/urpmi/rpms called 'media_info' containing the sort of info that you mentioned.

How am I now able to add it to my "Mandriva Local rpm database," as you suggest?

Under what conditions would I have to "download the same package twice." please?

BTW yes, I use want kde4.1.2.
__________________

GlennsPref 11-05-2008 12:13 AM

Hi Phidor.

You'd be best to move them(.rpm's) to another directory, as that is a system dir. and you won't be able to control what gets kept if you use rpmdrake (the GUI).

I have mine in a directory /local/Archive/rpms and I call it local-rpms, must be different to the system names. Maybe your home dir is big enough. For instance /home/phidor/rpms

Once you do that run, in my case

urpmi.addmedia Local-Rpms file://local/Archive/rpms with media_info/hdlist.cz

That will add Local-Rpms to my database.

Also, I discovered that if you get a failed download while using urpmi, add --resume

that should pickup any unfinished downloads,

these incomplete packages are usually named package.name.ver.rpm.part.

I haven't tried it yet.

You may get the double-up of packages if you do what I direct here.

However you will be stung for the download if you leave them (.rpm's) in the cache

as urpmi disregards any files there after install
(they are usually deleted and therefore not kept track of by default).

You can get around this by urpmi package.name --media Local-Rpms

urpmi will install those first.

I usually use genhdlist2 without the ./ but mostly the whole address...

genhdlist2 /local/Archive/rpms

The info you got is right, from genhdlist2.

hope this helps, Glenn

phidor 11-05-2008 01:38 AM

Thanks Glen! This last bit seems pretty straightforward. I really do appreciate the effort you have expended to get the detail clear.Thanks again, Philip (Phidor).

GlennsPref 11-05-2008 01:56 AM

I have just been going through a similar process to get my networked machine up-to-date.

So it was current anyway, and I don't mind.

The reason I use /local or /home

is that I have them on separate partitions from those of the system, especially /usr, /root and / ,

because these are the directories that are overwritten when re-installing(if you really have to),

for some (unknown) reason.

Eg, if you format / and your /home directory is on the same partition, say goodbye to /home.

That happends to me a bit, 2 times a year at least, lol.

Cheers Glenn

ps. now I'm trying to setup the permissions to access the nfs shared folders on my net. Any Tips? I can see the folders, but can't mount them. (new ground for me)

phidor 11-05-2008 08:31 PM

For interest: the CLI urpmi --noclean option has solved another irritating problem for me. I had no help system in Openoffice version 3 so,
I uninstalled the help that had been installed with the Mandriva package manager and then reinstalled, this time from the CLI using the --noclean option and behold, my OO3 help system is now there! Thanks - again - Glenn for your valued help!

Philip (Phidor)

GlennsPref 11-05-2008 08:35 PM

Hey, no worries, it's all in the help file, it's just knowing when to use it.

cheers, Glenn

Sscheme 03-02-2009 08:13 AM

Same thing happened to me i reinstall kde but it deleted most of packages that belongs to applications. How can i learn which packages removed by the command. I need something like the log of console operations.


All times are GMT -5. The time now is 07:11 AM.