Supported way, ala 'zypper dup' not working...what does it need?
On 2021/02/23 01:46, Simon Lees wrote:
On 2/23/21 5:31 PM, L A Walsh wrote:
Simon Lees wrote:
http://download.opensuse.org/distribution/leap/15.0/repo/oss/x86_64/rpm-4.14...
---
Another FWIW, I working on my download script being workable with leap-15.0 ....
Well the supported way to update a system is `zypper dup` we will make sure that works there should rarely be a need for an openSUSE user to call rpm directly, especially when installing / removing / upgrading packages.
---- Well, having pulled down that repo and the files in oss/repodata (repomd.xml, primary.xml, et al) I pointed zypper's "add-repo" with the "--check" flag at the 'repo', but it seems to be missing something:
sudo zypper up Error building the cache: [Leap15.0_OSS|file:/home/cache/suse/distribution/leap/15.0/repo/oss] Valid metadata not found at specified URL Warning: Skipping repository 'Leap15.0_OSS' because of the above error. Error building the cache: [Leap15.0_oss_src|file:/home/cache/suse/source/distribution/leap/15.0/repo/oss/] Valid metadata not found at specified URL Warning: Skipping repository 'Leap15.0_oss_src' because of the above error. Loading repository data... Reading installed packages... Nothing to do.
====== I tried tracing zypper's actions, but don't see any attempt to open any files (or any failures associated with such): # strace -ff -e open zypper up |& more strace: Process 72710 attached [pid 72710] +++ exited with 0 +++ --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=72710, si_uid=0, si_status=0, si_utime=1, si_stime=0} --- strace: Process 72711 attached strace: Process 72712 attached [pid 72712] +++ exited with 0 +++ [pid 72711] --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=72712, si_uid=0, si_status=0, si_utime=56, si_stime=16} --- [pid 72711] +++ exited with 0 +++ --- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=72711, si_uid=0, si_status=0, si_utime=0, si_stime=0} --- Error building the cache: [Leap15.0_OSS|file:/home/cache/suse/distribution/leap/15.0/repo/oss] Valid metadata not found at specified URL Warning: Skipping repository 'Leap15.0_OSS' because of the above error. Error building the cache: [Leap15.0_oss_src|file:/home/cache/suse/source/distribution/leap/15.0/repo/oss/] Valid metadata not found at specified URL Warning: Skipping repository 'Leap15.0_oss_src' because of the above error. Loading repository data... Reading installed packages... Nothing to do. +++ exited with 0 +++ ---- What files is zypper trying to find that are missing? It doesn't seem to be trying to open any files (!!?)...I'm not sure why strace isn't showing any open file attempts, though I admit to being a novice on using the "-e open" switch to limit filtering to open calls. Still any idea what files it might be wanting? It's not very specific... Thanks...
On 2021/03/08 14:00, L A Walsh wrote:
I tried tracing zypper's actions, but don't see any attempt to open any files (or any failures associated with such):
# strace -ff -e open zypper up |& more
Oop -- manpage for strace maybe needs updating, as it seems "open" isn't used much anymore...they are all "openat", calls... processing... (examining new information)...
On 2021-03-09 01:06, L A Walsh wrote:
manpage for strace maybe needs updating
No, not really. I believe that would only be cosmetic as it's just a an example in the manpage. But if it bugs you, you can always rewrite the manpage for the _example_ you're referring to and make a pull request. Mind you that open and openat has had a bit of heated arguments during the years on mailinglists and you can't expect glibc to always give you openat instead of open depending on distro. Certain commands needs a higher level of understanding of what they're actually doing. This one needs you to understand system calls and that there is plenty of them. There is over 600 system calls in glibc and 5 that starts with open. I always start by issuing -c (summary) for strace and then check the individual calls that seems to be appropriate. Example: strace -c cat /dev/null But for all that starts with "open", you're supposed to do regexp or comma separated for exact match. regexp strace -e trace=/open cat /dev/null exact match strace -e trace=open,open_by_handle_at,open_tree,openat,openat2 cat /dev/null -- /bengan
On 2021/03/09 02:24, Bengt Gördén wrote:
On 2021-03-09 01:06, L A Walsh wrote:
manpage for strace maybe needs updating
No, not really. I believe that would only be cosmetic as it's just a an example in the manpage.
I would have thought that maybe -E open might select all the open-type calls, but guess not.
But if it bugs you,
Not really -- just was answering my previous post about strace producing no output when I used -E open and that after finding the problem I was back to investigating my issues. (processing...).
Certain commands needs a higher level of understanding of what they're actually doing. This one needs you to understand system calls and that there is plenty of them. There is over 600 system calls in glibc and 5 that starts with open.
I always start by issuing -c (summary) for strace and then check the individual calls that seems to be appropriate.
---- Yeah, I don't use strace that often, and then only to find out what a command was last doing when it went off into "unexpected behavior"...
Example: strace -c cat /dev/null
But for all that starts with "open", you're supposed to do regexp or comma separated for exact match.
--- I used to know that, but never used it so .... my remembrance evaporated from disuse. ;^) Once I ran 'strace' with no "-E', I saw the problem.
regexp strace -e trace=/open cat /dev/null exact match strace -e trace=open,open_by_handle_at,open_tree,openat,openat2 cat /dev/null
--- Thanks for the reminder! ;-) -linda
On 3/8/21 4:00 PM, L A Walsh wrote:
Error building the cache: [Leap15.0_OSS|file:/home/cache/suse/distribution/leap/15.0/repo/oss] Valid metadata not found at specified URL
In the really old days, after downloading the rpms, we used to have to create the metadata with createrepo. IIRC that generates the sqlite metadata tables. (but this was more than a decade ago...) -- David C. Rankin, J.D.,P.E.
* David C. Rankin <drankinatty@suddenlinkmail.com> [03-08-21 23:20]:
On 3/8/21 4:00 PM, L A Walsh wrote:
Error building the cache: [Leap15.0_OSS|file:/home/cache/suse/distribution/leap/15.0/repo/oss] Valid metadata not found at specified URL
In the really old days, after downloading the rpms, we used to have to create the metadata with createrepo. IIRC that generates the sqlite metadata tables. (but this was more than a decade ago...)
I still do for a few *special* packages. and works just like before -- (paka)Patrick Shanahan Plainfield, Indiana, USA @ptilopteri http://en.opensuse.org openSUSE Community Member facebook/ptilopteri Photos: http://wahoo.no-ip.org/piwigo paka @ IRCnet freenode
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Monday, 2021-03-08 at 14:00 -0800, L A Walsh wrote:
On 2021/02/23 01:46, Simon Lees wrote:
On 2/23/21 5:31 PM, L A Walsh wrote:
Simon Lees wrote:
...
====== I tried tracing zypper's actions, but don't see any attempt to open any files (or any failures associated with such):
# strace -ff -e open zypper up |& more
Did you have a look at the zypper logs first? They are very detailed. There is "/var/log/zypp/history" but you do not want that one. Instead, look at "/var/log/YaST2/y2log*". I suspect some zypper operations get logged. Maybe not. Ok, not at all. Then, look at /var/log/zypper.log I did a zypper refresh and it wrote 3580 lines. - -- Cheers, Carlos E. R. (from openSUSE 15.2 x86_64 at Telcontar) -----BEGIN PGP SIGNATURE----- iHoEARECADoWIQQZEb51mJKK1KpcU/W1MxgcbY1H1QUCYEdn1Rwccm9iaW4ubGlz dGFzQHRlbGVmb25pY2EubmV0AAoJELUzGBxtjUfV5Q4AoIAGHkmhOPXwlVI1xjnq rx2Bq3K3AJ94WdP6NHDw9f0p9vDXBtD/kstysA== =hvRs -----END PGP SIGNATURE-----
On 3/8/21 4:00 PM, L A Walsh wrote:
Error building the cache: [Leap15.0_OSS|file:/home/cache/suse/distribution/leap/15.0/repo/oss] Valid metadata not found at specified URL
On 2021/03/09 04:19, Carlos E. R. wrote:
Did you have a look at the zypper logs first? They are very detailed.
Didn't know where those logs were nor that they were kept, but I figured the program probably made kernel calls, so that's why I hit strace first. Second place to hit was using the 'verbose' option on zypper. Problem was zypper didn't like that repomd.xml referenced files in 'repodata' for other languages that I didn't download. Soooo, instead I edited 'repomd.xml' and removed the files I didn't need. Now zypper only issues a warning about a checksum mismatch and asked me if I wanted to proceed -- I said yes, and it stores the exception.
I did a zypper refresh and it wrote 3580 lines.
--- Yikes!, information overload. The verbose option told me it was missing alt-language files -- only listed the 1st one which gave me the idea to delete them from the repomd.xml file.
On 10/03/2021 23.13, L A Walsh wrote:
On 3/8/21 4:00 PM, L A Walsh wrote:
Error building the cache: [Leap15.0_OSS|file:/home/cache/suse/distribution/leap/15.0/repo/oss] Valid metadata not found at specified URL
On 2021/03/09 04:19, Carlos E. R. wrote:
Did you have a look at the zypper logs first? They are very detailed.
Didn't know where those logs were nor that they were kept, but I figured the program probably made kernel calls, so that's why I hit strace first.
First thing I do with any program is search for possible log files under /var/log/somewhere. Or ask.
Second place to hit was using the 'verbose' option on zypper.
Problem was zypper didn't like that repomd.xml referenced files in 'repodata' for other languages that I didn't download. Soooo, instead I edited 'repomd.xml' and removed the files I didn't need. Now zypper only issues a warning about a checksum mismatch and asked me if I wanted to proceed -- I said yes, and it stores the exception.
Why do you things that complicated? :-o :-? Just download everything, if you must have a local repo, and edit nothing. Disk space is cheap. And surely you are not strained on bandwidth or an internet download cap. -- Cheers / Saludos, Carlos E. R. (from 15.2 x86_64 at Telcontar)
participants (5)
-
Bengt Gördén
-
Carlos E. R.
-
David C. Rankin
-
L A Walsh
-
Patrick Shanahan