You are not logged in.
Fom the front page news:
Pacman 3.0.5-1 had a bit of an issue with permissions when installing packages that contained symlinks. A well-intentioned chmod call turned permissions on some files to 777 creating a security risk. This has been fixed in pacman 3.0.5-2.
More details:
http://bugs.archlinux.org/task/7461
http://archlinux.org/pipermail/pacman-d … 08579.html
Offline
From pacman update notice:
It is recommended you reinstall any packages you have installed since upgrading to version 3.0.5-1. Use /var/log/pacman.log for this information.
Am I correct in assuming that just doing "pacman -S <packages>" and answering yes for the whole lot (the already up to date questions) will fix this?
Last edited by [vEX] (2007-06-21 07:16:19)
PC: Antec P182B | Asus P8Z77-V PRO | Intel i5 3570k | 16GB DDR3 | GeForce 450GTS | 4TB HDD | Pioneer BDR-207D | Asus Xonar DX | Altec Lansing CS21 | Eizo EV2736W-BK | Arch Linux x86_64
HTPC: Antec NSK2480 | ASUS M3A78-EM (AMD 780G) | AMD Athlon X3 425 | 8GB DDR2 | GeForce G210 | 2TB HDD | Arch Linux x86_64
Server: Raspberry Pi (model B) | 512MB RAM | 750GB HDD | Arch Linux ARM
Offline
You can even use the --noconfirm flag to avoid answering yes - see man pacman.
Offline
I installed the upgraded a lot after installing pacman - as in I installed Arch yesterday! So my whole system minus the base packages needs reinstalled.
Can someone help me with a bash script to do the reinstall. So far I have done:
pacman -Q | grep -v "pacman" > packages.txt
then trying a bash script like:
for i in packages.txt
do
pacman -S $i
done
but that fails. Replacing the "pacman -S $i" with "cat $i" does print the package names as I expect.
Thanks
Offline
Did this permission issue apply to upgraded packages too?
I installed the upgraded a lot after installing pacman - as in I installed Arch yesterday! So my whole system minus the base packages needs reinstalled.
Can someone help me with a bash script to do the reinstall. So far I have done:
pacman -Q | grep -v "pacman" > packages.txt
then trying a bash script like:
for i in packages.txt do pacman -S $i done
but that fails. Replacing the "pacman -S $i" with "cat $i" does print the package names as I expect.
Thanks
Your "for i in packages.txt" just loops over 'packages.txt' filename, so you obtain a single "pacman -S packages.txt" call; cat works fine cause it outputs the content of the given package (see "man cat"); something like
pacman -S `cat packages.txt`
would do the job in a single pacman call.
Last edited by thujone (2007-06-21 10:12:20)
Offline
pacman -Q | grep -v "pacman" > packages.txt
replace that with
pacman -Q | grep -v pacman | cut -d' ' -f1 > packages.txt
this will remove the version numbers, so you're left with just the package names
then do what thujone suggested
Stand back, intruder, or i'll blast you out of space! I am Klixon and I don't want any dealings with you human lifeforms. I'm a cyborg!
Offline
Thanks, that work perfectly. I obviously still suck at bash scripting and linux commands!
Last edited by Allan (2007-06-21 11:21:53)
Offline
Also, don't forget to reinstall pacman 3.0.5-2 itself.
After I reinstalled all the other packages I had upgraded in the last three days, I still had a file with 777 permission:
/usr/lib/libalpm.so.1.0.0
... which is owned by pacman.
Offline
here's a oneliner to do this:
pacman -Sy pacman && pacman -S $( tail -n$(( \
$( wc -l /var/log/pacman.log | cut -d' ' -f1 ) \
- $( grep -n "upgraded pacman .* -> 3.0.5-1" /var/log/pacman.log | awk -F: '{print $1}' )\
)) /var/log/pacman.log \
| awk '/\] upgraded |\] installed/ { if ($4 != "pacman") print $4}' \
| sort | uniq )
i broke it down a bit to make it more readable
And i was to lazy to filter out everything that was installed after the upgrade to pacman-3.0.5-2
Last edited by klixon (2007-06-21 14:48:06)
Stand back, intruder, or i'll blast you out of space! I am Klixon and I don't want any dealings with you human lifeforms. I'm a cyborg!
Offline
Apparently, the upgrade of libarchive caused new problems : http://archlinux.org/pipermail/arch/200 … 14931.html
http://bugs.archlinux.org/task/7484
I'm not sure how common that setup is (not too much I hope).
About the above script :
Why not using tail -n+ ?
Also in case pacman 3.0.5-1 has been upgraded several times, I think grep should use the first time (first line number it gets).
echo $( tail -n+$(grep -n "pacman .* -> 3.0.5-1" /var/log/pacman.log \
| awk -F: '{print $1}' | head -n 1) /var/log/pacman.log \
| awk '/\] upgraded |\] installed/ { if ($4 != "pacman") print $4}' \
| sort | uniq )
Also, this doesn't work with localized pacman.
Since I don't know awk, I wasn't even able to fix the third line for the french version.
example output :
[2007-06-21 01:33] mplayer-plugin désinstallé (3.40-2)
[2007-06-21 11:47] libarchive mis à jour (2.2.3-2 -> 1.3.1-2)
[2007-06-21 11:47] pacman mis à jour (3.0.5-2 -> 3.0.5-1)
[2007-06-21 12:37] libarchive mis à jour (1.3.1-2 -> 2.2.3-2)
[2007-06-21 12:37] pacman mis à jour (3.0.5-1 -> 3.0.5-2)
[2007-06-21 12:37] filesystem mis à jour (0.8-7 -> 0.8-9)
[2007-06-21 14:22] transfig installé (3.2.4-2)
I could probably find another way for doing it, but I'm curious about how to adopt the awk way
Otherwise, this security problem with wrong permission is a non issue on all desktop single-user system, right ?
I see how it is a big problem on public and open systems that many users have access too, but not in other cases. Please enlighten me
pacman roulette : pacman -S $(pacman -Slq | LANG=C sort -R | head -n $((RANDOM % 10)))
Offline
hmmm tail --help didn't show the "-n+" option and head --help did show the "-n-" so i assumed tail didn't have this (man-page would've told me i guess... )
echo $( tail -n+$(grep -n "pacman .* -> 3.0.5-1" /var/log/pacman.log \
| awk -F: '{print $1}' | head -n 1) /var/log/pacman.log \
| awk '/ mis à jour \(| installé \(/ { if ($4 != "pacman") print $4}' \
| sort | uniq )
should do the trick i think, but you might want to check the output of
grep " mis à jour \(\| installé \(" /var/log/pacman.log
beforehand to see if you don't match to much or to little on the awk regexp
Stand back, intruder, or i'll blast you out of space! I am Klixon and I don't want any dealings with you human lifeforms. I'm a cyborg!
Offline
hmmm tail --help didn't show the "-n+" option and head --help did show the "-n-" so i assumed tail didn't have this (man-page would've told me i guess... )
echo $( tail -n+$(grep -n "pacman .* -> 3.0.5-1" /var/log/pacman.log \ | awk -F: '{print $1}' | head -n 1) /var/log/pacman.log \ | awk '/ mis à jour \(| installé \(/ { if ($4 != "pacman") print $4}' \ | sort | uniq )
should do the trick i think
nearly, just had to replace the two $4 by $3 (since it isn't in the same order). great job
but you might want to check the output of
grep " mis à jour \(\| installé \(" /var/log/pacman.log
beforehand to see if you don't match to much or to little on the awk regexp
I had to use this rather :
grep -E " mis à jour \(| installé \(" /var/log/pacman.log
It looks like this matches all packages correctly, thanks
I hope it'll be useful to others.
pacman roulette : pacman -S $(pacman -Slq | LANG=C sort -R | head -n $((RANDOM % 10)))
Offline
nearly, just had to replace the two $4 by $3 (since it isn't in the same order). great job
I was a bit in a hurry, sorry glad you figured it out
It looks like this matches all packages correctly, thanks
I hope it'll be useful to others.
Thanks for your input. You made it a lot cleaner
Stand back, intruder, or i'll blast you out of space! I am Klixon and I don't want any dealings with you human lifeforms. I'm a cyborg!
Offline
Apparently, the upgrade of libarchive caused new problems : http://archlinux.org/pipermail/arch/200 … 14931.html
http://bugs.archlinux.org/task/7484
I'm not sure how common that setup is (not too much I hope).
Well affects me too (I have /opt symlinked to /usr/opt), but it's not limited to /opt. If anyone ever linked a folder to a different place and reinstalled a package that is using that directory, it's messed up!
I don't think I personally did do that on anything else besides /opt but I honestly might not remember it anymore from when I set my system up a long time ago (my arch isn't that old yet (maybe 6 months), but think about all the people who set their system up years ago.. (for example my slackware system I set up more than 5 years ago... way to remember if during that period of time I symlinked something.....)
Offline