*Participation Requested*
MicroOS Desktop Use to Help with ALP Feedback
-
Re: zypper dup installed mariadb on a server
 Originally Posted by arvidjaar
I doubt all other of 4115 installed packages do not really need glibc
Kinda shame, I remember using -wr in the past with decent results.
.: miuku @ #opensuse @ irc.libera.chat
|
-
Re: zypper dup installed mariadb on a server
 Originally Posted by Miuku
Kinda shame, I remember using -wr in the past with decent results.
Packages require the libraries directly, not some specific lib package, at least for the dependencies auto-generated by rpmbuild.
So, packages require i.e. libc.so.6, not glibc.
Try "rpm -q --whatrequires libc.so.6" and you'll get a much longer list... 
But of course, you will miss packages then that do require glibc, and not libc.so.6.
Another option would be to use zypper though:
Code:
zypper se -i --requires glibc
This will list all installed packages ('-i' means to only list installed ones) that require the package glibc.
And "zypper se" also has these options: --recommends, --conflicts, --suggests, --obsoletes
I think you can even combine several into one query.
But even with zypper, "zypper se --requires mariadb" won't find much (only the mariadb packages themselves, and the akonadi _source_ package), you need to specify "mysql" as well. In the case of glibc and other libraries, it seems to be fine though.
-
Re: zypper dup installed mariadb on a server
 Originally Posted by wolfi323
Code:
zypper se -i --requires glibc
This will list all installed packages ('-i' means to only list installed ones) that require the package glibc.
I would not rely on this. It does no miracles.
Code:
bor@opensuse:~> LC_ALL=C LANG=C zypper --no-refresh se -i --requires --match-exact glibc
Loading repository data...
Reading installed packages...
S | Name | Summary | Type
--+--------------+-----------------------------------------------------+--------
i | glibc-devel | Include Files and Libraries Mandatory for Develop-> | package
i | glibc-extra | Extra binaries from GNU C Library | package
i | glibc-locale | Locale Data for Localized Programs | package
i | liblockdev1 | The header files for the lockdev library | package
i | nscd | Name Service Caching Daemon | package
i | valgrind | Memory Management Debugger | package
bor@opensuse:~>
It looks like it returns all packages because by default zypper does case insensitive substring search and so matches something like
Code:
bor@opensuse:~> rpm -q --provides glibc | grep GLIBC
ld-linux-x86-64.so.2(GLIBC_2.2.5)(64bit)
ld-linux-x86-64.so.2(GLIBC_2.3)(64bit)
ld-linux-x86-64.so.2(GLIBC_2.4)(64bit)
libBrokenLocale.so.1(GLIBC_2.2.5)(64bit)
libanl.so.1(GLIBC_2.2.5)(64bit)
...
I really miss real recursive dependencies search as was present in URPM toolset.
-
Re: zypper dup installed mariadb on a server
 Originally Posted by arvidjaar
It looks like it returns all packages because by default zypper does case insensitive substring search and so matches something like
You're probably right, yes.
But I'd say that's exactly what you want in this case, i.e. for finding out what requires glibc.
And it should also work with other lib packages, as a package would either require libxxx or libxxx.so.x.
Of course it doesn't.
But I suppose URPM does neither... 
Never used that though, so I'm not really sure what you mean exactly with "recursive dependencies search".
That package x is listed as requiring z, if it requires y which in turn requires z?
For that "zypper rm" as you wrote (maybe with the --dry-run/-D option) is probably the best way, yes.
Or "rpm -e --test xxx".
-
Re: zypper dup installed mariadb on a server
 Originally Posted by wolfi323
And it should also work with other lib packages, as a package would either require libxxx or libxxx.so.x.
Code:
bor@opensuse:~> LC_ALL=C LANG=C zypper --no-refresh se -i --requires libopenssl1_0_0
Loading repository data...
Reading installed packages...
S | Name | Summary | Type
--+------------------+-------------------------------------------------+--------
i | libopenssl-devel | Include Files and Libraries mandatory for Dev-> | package
bor@opensuse:~> rpm -q --provides libopenssl1_0_0
libcrypto.so.1.0.0()(64bit)
libgost.so()(64bit)
libopenssl1_0_0 = 1.0.1k-2.24.1
libopenssl1_0_0(x86-64) = 1.0.1k-2.24.1
libpadlock.so()(64bit)
libssl.so.1.0.0()(64bit)
bor@opensuse:~> LC_ALL=C LANG=C zypper --no-refresh se -i --requires 'libssl.so.1.0.0()(64bit)'
Loading repository data...
Reading installed packages...
S | Name | Summary | Type
--+----------------------------+---------------------------------------+--------
i | cups | The Common UNIX Printing System | package
i | cups-libs | Libraries for CUPS | package
i | git-core | Core git tools | package
i | gnome-vfs2 | The GNOME 2.x Desktop Virtual File -> | package
... long list
But I suppose URPM does neither...
When user asks question "which packages require package foo" user is actually interested in answer similar to"can I remove package foo without breaking my system", or, in reverse, "what packages must I install additionally if I want to install package foo". zypper answers different question - what package has "provide" attribute that matches string "foo". This is entirely different and too low level to be of real use. It is useful, but for a developer, not a user.
urmpq gave exactly the right answer. "urpmq --requires foo" prints the list of packages that require package foo. This is effectively
Code:
for i in $(rpm -q --provides foo); do
zypper search --match-exact $i
done
except zypper does not provide nice scripting interface for it.
That package x is listed as requiring z, if it requires y which in turn requires z?
That was "urpmq --requires-recursive". It is effectively list you get when you try "zypper rm".
-
Re: zypper dup installed mariadb on a server
 Originally Posted by wolfi323
This message is printed on installation or update of the package if no database tables exist.
It should have been printed during the original installation too.
The question is whether this makes sense on updates...
Thanks again. In the mean time I've installed a remove/install cycle of mariadb to see if it re-shows the message and it does.
Since I'm not in need of mariadb right now, but might need it in the future I think that is great.
Finally I got rid of both mariadb stuff and ensured the pattern is also gone and tested if the dup doesn't reinstall them:
Code:
zypper remove patterns-openSUSE-lamp_server
zypper remove mariadb-client mariadb-errormessages
zypper dup
Everything is fine now. Thanks again.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|