9,13 → 9,13 |
# configure the RPM repository |
|
Lang=`echo $LANG|cut -c 1-2` |
VERSION="2" |
VERSION="4" |
ARCH="i586" |
# The kernel version we compile netflow for |
KERNEL="kernel-desktop-3.4.52-1.mga2-1-1.mga2" |
ModuleTree="kernel-desktop-3.4.52-1.mga2" |
#KERNEL="kernel-desktop-3.4.52-1.mga2-1-1.mga2" |
#ModuleTree="kernel-desktop-3.4.52-1.mga2" |
# ****** Alcasar needed RPMS - paquetages nécessaires au fonctionnement d'Alcasar ****** |
PACKAGES="sudo freeradius freeradius-mysql freeradius-ldap freeradius-web apache-mpm-prefork apache-mod_ssl apache-mod_php iptables squid dansguardian postfix mariadb logwatch ntp bind-utils openssh-server php-xml php-ldap php-mysql pam_ccreds rng-utils dnsmasq syslinux rsync cronie-anacron clamav pm-fallback-policy php-mbstring perl-rrdtool perl-MailTools perl-Socket6 php-sockets fail2ban gnupg man ipset" |
PACKAGES="freeradius freeradius-mysql freeradius-ldap freeradius-web apache apache-mod_ssl apache-mod_php iptables squid dansguardian postfix mariadb ntp bind-utils openssh-server php-xml php-ldap php-mysql php-mbstring php-sockets rng-utils dnsmasq rsync clamav pm-fallback-policy perl-rrdtool perl-MailTools perl-Socket6 fail2ban gnupg man ipset" |
|
rpm_repository_sync () |
{ |
41,7 → 41,7 |
echo "If this problem occurs again, change the MIRRORLIST[1&2] variables in the file 'scripts/alcasar-urpmi.sh'" |
fi |
} |
# extract the current Mandriva/Mageia version and hardware architecture (i586 ou X64) |
# extract the current Mageia version and hardware architecture (i586 ou X64) |
fic=`cat /etc/product.id` |
unknown_os=0 |
old="$IFS" |
66,7 → 66,7 |
fi |
done |
IFS="$old" |
if [[ ( $unknown_os != 3 || "$DISTRIBUTION" != "Mageia" ) && ( "$CURRENT_VERSION" != "2" ) ]] |
if [[ ( $unknown_os != 3 || "$DISTRIBUTION" != "Mageia" ) && ( "$CURRENT_VERSION" != "4" ) ]] |
then |
if [ $Lang == "fr" ] |
then |
82,11 → 82,11 |
if [ $Lang == "fr" ] |
then |
echo "1 - Récupérez le fichier de configuration actuel (/tmp/alcasar-conf.tar.gz)." |
echo "2 - Installez Linux-Mageia2 (cf. doc d'installation)" |
echo "2 - Installez Linux-Mageia4 (cf. doc d'installation)" |
echo "3 - copiez le fichier 'alcasar-conf.tar.gz' dans le répertoire '/tmp' avant de lancer l'installation d'ALCASAR" |
else |
echo "1 - Retrieve the configuration file (/tmp/alcasar-conf.tar.gz)" |
echo "2 - Install Linux-Mageia2 (cf. installation doc)" |
echo "2 - Install Linux-Mageia4 (cf. installation doc)" |
echo "3 - Copy the file 'alcasar-conf.tar.gz' in the folder '/tmp' before launching the installation of ALCASAR" |
fi |
fi |
138,6 → 138,7 |
fi |
fi |
done |
|
# delete unused RPMs |
if [ $Lang == "fr" ] |
then |
145,22 → 146,22 |
else |
echo "Nettoyage du système : " |
fi |
for rm_rpm in shorewall mandi radeontool avahi awstats |
for rm_rpm in shorewall mandi radeontool mesa avahi |
do |
/usr/sbin/urpme --auto $rm_rpm --auto-orphans 2>/dev/null |
echo -n "." |
done |
# download the kernel used by ALCASAR and fix its version |
if [ $Lang == "fr" ] |
then |
echo "Récupération du noyau Linux exploité par ALCASAR. Veuillez patienter ..." |
else |
echo "Download the Linux kernel used by ALCASAR. Please wait ..." |
fi |
urpmi --auto --quiet $KERNEL |
echo "/^kernel/" > /etc/urpmi/skip.list |
#if [ $Lang == "fr" ] |
#then |
# echo "Récupération du noyau Linux exploité par ALCASAR. Veuillez patienter ..." |
#else |
# echo "Download the Linux kernel used by ALCASAR. Please wait ..." |
#fi |
#urpmi --auto --quiet $KERNEL |
#echo "/^kernel/" > /etc/urpmi/skip.list |
# download "timezone" to avoid a mageia issue --> should be remove with mageia3 |
urpmi timezone |
#urpmi timezone |
# download updated RPM in cache |
if [ $Lang == "fr" ] |
then |
233,17 → 234,18 |
rpm_error |
exit 1 |
fi |
# Keep only the kernel version we compil netflow with, and remove all others |
kernelVersion=$(rpm -qa | grep "kernel-desktop") |
for i in $kernelVersion |
# Keep only the last kernel version |
#kernelVersion=$(rpm -qa | grep "kernel-desktop") |
#for i in $kernelVersion |
#do |
# if [ ! $i = $KERNEL ];then |
# urpme --auto $i |
# fi |
#done |
echo "STOP"; read a |
# delete unused services |
for rm_rpm in c-icap-server mageia-gfxboot-theme |
do |
if [ ! $i = $KERNEL ];then |
urpme --auto $i |
fi |
done |
# delete old alcasar RPMs and unused services |
for rm_rpm in c-icap-server lib64chilli0 libchilli0 python-coova-chilli cyrus-sasl mageia-gfxboot-theme |
do |
/usr/sbin/urpme --auto $rm_rpm --auto-orphans 2>/dev/null |
done |
|