Fedora
From Alessandro's Wiki
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
Gestore Pacchetti Software RPM
- Come avere la lista degli rpm installati ordinati per dimensione?
rpm -qa --qf "%-10{SIZE} %-30{NAME}\n" | sort -n
- sapere a che rpm appartiene un pacchetto:
rpm -q --whatprovides libltdl.so.3 libtool-libs-1.4.3-6
- install repository gpg-key from file/url
# rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-23-x86_64
# rpm --import (url)
dnf
Updates
dnf groupupdate 'Minimal Install'
Cleanup Packages
- Find unused config files + Merge and resolve the changes found by the following script:
dnf install rpmconf; rpmconf -a.
- Find and remove old config which nobody owns:
rpmconf -c
- packages not required by other packages with the tool package-cleanup from the yum-utils package:
dnf install yum-utils; package-cleanup --leaves
- find orphaned packages
- (i.e. packages not in the repositories anymore) with package-cleanup --orphans
- (partially uninstalled but where the "%postun" script failed)
dnf install rpmreaper
Major Version Update
dnf install fedora-upgrade fedora-upgrade
dnf system-upgrade download --refresh --releasever=35 --allowerasing
Yum (old)
- gestore repositori Fedora/RedHat
Repositories
- Livna:
rpm -ivh http://rpm.livna.org/livna-release-6.rpm
- Remi:
wget http://remi.collet.free.fr/rpms/fc6.i386/remi-release-1-2.fc6.remi.noarch.rpm rpm -ivh remi-release-1-2.fc6.remi.noarch.rpm wget http://remi.collet.free.fr/RPM-GPG-KEY-remi rpm --import RPM-GPG-KEY-remi
- ATrpms
echo '[atrpms] name=Fedora Core $releasever - $basearch - ATrpms baseurl=http://dl.atrpms.net/fc$releasever-$basearch/atrpms/stable gpgkey=http://ATrpms.net/RPM-GPG-KEY.atrpms gpgcheck=1' > /etc/yum.repos.d/atrpms.repo
rpm --import http://ATrpms.net/RPM-GPG-KEY.atrpms
- block a package globally: /etc/yum.conf
exclude=firefox
- block a package from in a repository: /etc/yum.repos.d/repository_name.repo
exclude=package_name
example
- in scientific linux 6.1 , with rpmforge,epel,adobe I have a problem upgrading the syst em after installing VLC:
[root@clustergang01 ~]# yum update Loaded plugins: refresh-packagekit epel/metalink | 16 kB 00:00 Setting up Update Process Resolving Dependencies --> Running transaction check ---> Package libmodplug.i686 0:0.8.7-1.el6.rf will be updated --> Processing Dependency: libmodplug.so.0 for package: vlc-1.1.11-1.el6.rf.i686 ---> Package libmodplug.i686 1:0.8.8.3-2.el6 will be an update --> Finished Dependency Resolution Error: Package: vlc-1.1.11-1.el6.rf.i686 (@rpmforge) Requires: libmodplug.so.0 Removing: libmodplug-0.8.7-1.el6.rf.i686 (@rpmforge) libmodplug.so.0 Updated By: 1:libmodplug-0.8.8.3-2.el6.i686 (epel) Not found
- so I "ban"
exclude=libupnp,libmodplug
from
/etc/yum.repos.d/epel.repo
Install development Kernel
yum --enablerepo=development update kernel
multi-user.target
systemctl isolate multi-user.target
networking
- add a static route to the network scripts:
in /etc/sysconfig/network-scripts/route-eth1
192.168.251.0/24 dev eth1 via 192.168.252.1
is the equivalent of doing:
route add -net 192.168.251.0/24 gw 192.168.252.1
BUGS & Problems
USB storage devices
- Usb storage devices (Hard disks, pen drives, cd/dvd) are not working
se facendo:
modprobe usb_storage
oppure
[root@localhost ~]# dmesg |grep usb_storage|tail -3 usb_storage: Unknown symbol scsi_scan_host usb_storage: Unknown symbol scsi_add_host usb_storage: Unknown symbol scsi_host_alloc
si hanno questi errori, una soluzione che ho trovato su un portatile Acer Centrino è:
vi /etc/modprobe.d/scsi_mod
e commento la linea
# options scsi_mod max_scsi_luns=6
provo e inserisco il modulo in memoria:
modprobe usb_storage [root@localhost ~]# modinfo usb_storage filename: /lib/modules/2.6.20-1.2925.fc6/kernel/drivers/usb/storage/usb-storage.ko license: GPL description: USB Mass Storage driver for Linux author: Matthew Dharm <mdharm-usb@one-eyed-alien.net> srcversion: F3B413F507F36B5282158A7 depends: scsi_mod vermagic: 2.6.20-1.2925.fc6 SMP mod_unload 686 4KSTACKS parm: delay_use:seconds to delay before using a new device (uint)
Risolto