Skip to content

{ Category Archives } Linux

remove files older than 7 days

we can use a simple one line for this: #!/bin/sh VERZ=”/home/cobackup/wiki/” ALTER=”7″ cd $VERZ find . -mtime +$ALTER -exec rm {} \; and we can edit crontab  running this script every day 0 22 * * * /bin/sh /root/scripts/delfile.sh > /dev/null 2>&1

Tagged

How to change the Hostname of a Linux system

Change the hostname on a running system On any Linux system you can change its hostname with the command ‘hostname‘ (surprised?)… Here are some quick usages of the command line hostname: hostname without any parameter it will output the current hostname of the system. hostname –fqd it will output the fully qualified domain name (or […]

Tagged

Installation phpmyadmin on SLES 11

1.)first you can download source code 2.) Untar the source code in your webserver’s document root 3.) create softlink to directory selim:/srv/www/htdocs # ls -l total 20 drwxr-xr-x 2 root root 4096 May 21 15:19 gif drwxr-xr-x 2 root root 4096 Jul 28 18:07 hosts -rw-r–r– 1 root root 130 Jun 1 11:27 index.html -rw-r–r– […]

Tagged ,

problem with manaul editing config files and suSEconfig

here is example: after running suSEconfig.. Executing /sbin/conf.d/SuSEconfig.postfix… *** WARNING *** Found /etc/postfix/main.cf.SuSEconfig, exiting… *** WARNING *** Solution: delete the file /etc/postfix # rm -rf main.cf.SuSEconfig and then run # cat /etc/postfix/main.cf | grep -v ‘^#’ | md5sum >/var/adm/SuSEconfig/md5/etc/postfix/main.cf run again suSEconfig /etc/postfix # SuSEconfig you can see …. Executing /sbin/conf.d/SuSEconfig.postfix… Setting up postfix local […]

Secure Directory with HtAccces

Step1 Create htaccess file htpasswd -c passfile selim I wish to secure /usr/share/phpmyadmin < Directory "/usr/share/phpmyadmin" > Options -Indexes FollowSymLinks DirectoryIndex index.php AuthType Basic AuthName “Gesicherte Bereich” AuthUserFile /etc/phpmyadmin/passfile require valid-user < /Directory >

APC ‘unsupported protocol’

I want to install php-extension APC over PECL. I get this error: pecl.php.net is using a unsupported protocal – This should never happen. install failed I found on blog.pear.php.net this solution: Some PEAR installations on PHP 5.2.9 and 5.2.10 seem to be corrupted. When trying to install something, you will get the error: pear.php.net is […]

Tagged ,

implementing trash with samba

edit /etc/samba/smb.conf create new share [public] comment = public folder path = /home/diesdas/public read only = No create mask = 0777 directory mask = 0777 vfs object = recycle (SAMBA ADDON FOR TRASH) recycle:repository = /home/.Papierkorb recycle:keeptree = yes recycle:exclude = *.tmp *.temp *.swp *.o *.obj ~s* Backup* AUTOBACKUP* recycle:exclude_dir = /tmp /temp /cache /.Cache […]

Tagged ,

Steps for linux installation over Network

REDHAT 5 In this example we would be to install Redhat5 Linux steps: 1.Create or download ISO image for RH5 2.Create a directory in your web root: /srv/www/linux/RH5/i386 3.Mount the DVD ISO image to the web root: -mount -t iso9660 -o loop RH5.iso /srv/www/linux/RH5/i386 4. Test access the Directory PATH using a web browser — […]

Tagged , , ,

Joomla installation on Debian Etch

first I have created one Account for joomla useradd -m -c “user joomla” -s /bin/false -g users joomla 1. DOWNLOAD Joomla Copy  de-DE_joomla_lang_full.1.5.10v1.zip   file into a directory /home/joomla # cd /home/Joomla Extract the files e.g. # unzip  de-DE_joomla_lang_full.1.5.10v1.zip

Tagged ,

forget mysql root password

follow this STEPS and reset your root PASSWORD 1.) root@kraneis:~# /usr/bin/mysqld_safe –skip-grant-tables –user=root & [1] 13245 root@kraneis:~# nohup: ignoring input and redirecting stderr to stdout Starting mysqld daemon with databases from /var/lib/mysql mysqld_safe[13287]: started

Tagged