qmail with plesk

Some short commands List out all messages currently in queue by running: /var/qmail/bin/qmail-qread Count the number of messages in the queue currently by running: /var/qmail/bin/qmail-qstat Delete all mails from queue /usr/local/psa/admin/sbin/mailqueuemng -D  
read more

Download java with wget

Well to download java using wget  you can do like this wget --no-check-certificate --no-cookies --header \ "Cookie: oraclelicense=accept-securebackup-cookie" \ http://download.oracle.com/otn-pub/java/jdk/8u73-b02/jdk-8u73-linux-x64.rpm
read more

letsencrypt plesk problem

Well today a new problem. I have try to install the letsencrypt  module on a plesk centos 6 server . That have python 2.6 and you will get a warning I think that is not working with python2.6 but the problem is other module. The error’s look something like this Fehler: Fehler bei der Installation des SSL-Zertifikats von Let’s Encrypt: Failed letsencrypt execution: /usr/local/psa/var/modules/letsencrypt/venv.gUBSl/lib/python2.6/site-packages/cryptography/__init__.py:25: DeprecationWarning: Python 2.6 is no longer supported by the Python core team, please upgrade your Python. DeprecationWarning Traceback (most recent call last): File "/usr/local/psa/var/modules/letsencrypt/venv/bin/letsencrypt", line 11, in <module> sys.exit(main()) File "/usr/local/psa/var/modules/letsencrypt/venv.gUBSl/lib/python2.6/site-packages/letsencrypt/cli.py", line 1950, in main plugins = plugins_disco.PluginsRegistry.find_all() File "/usr/local/psa/var/modules/letsencrypt/venv.gUBSl/lib/python2.6/site-packages/letsencrypt/plugins/disco.py", line 168, in find_all plugin_ep = PluginEntryPoint(entry_point) File "/usr/local/psa/var/modules/letsencrypt/venv.gUBSl/lib/python2.6/site-packages/letsencrypt/plugins/disco.py", line 31, in __init__ self.plugin_cls = entry_point.load() File "/usr/local/psa/var/modules/letsencrypt/venv.gUBSl/lib/python2.6/site-packages/pkg_resources/__init__.py", line 2201, in load self.require(*args, **kwargs) File "/usr/local/psa/var/modules/letsencrypt/venv.gUBSl/lib/python2.6/site-packages/pkg_resources/__init__.py", line 2218, in require items = working_set.resolve(reqs, env, installer) File "/usr/local/psa/var/modules/letsencrypt/venv.gUBSl/lib/python2.6/site-packages/pkg_resources/__init__.py", line 835, in resolve raise VersionConflict(dist, req).with_context(dependent_req) ContextualVersionConflict: (cryptography 1.1 (/usr/local/psa/var/modules/letsencrypt/venv.gUBSl/lib/python2.6/site-packages), Requirement.parse(‘cryptography>=1.3’), set([‘PyOpenSSL’]))   The problem actually is the crypthography module. So the fix is cd /usr/local/psa/var/modules/letsencrypt/venv/bin ./pip install –upgrade...
read more

Comodo intermediate certificate

Well when try to install a ssl certificate from comodo they send you a zip with 4 files. AddTrustExternalCARoot.crt COMODORSAAddTrustCA.crt COMODORSADomainValidationSecureServerCA.crt www_domain_com.crt If you want to install this on apache it sholuld be something like this SSLCertificateFile /path/www_domain_com.crt SSLCertificateKeyFile /path/www_domain_com.key SSLCACertificateFile /path/intermediate.crt Where intermediate.crt is cat COMODORSADomainValidationSecureServerCA.crt COMODORSAAddTrustCA.crt AddTrustExternalCARoot.crt >...
read more

Remove all files created before a certain date

What I want is to delete manually all e-mail that are before 01/01/2015 The command is find /directory/path -type f ! -newermt 2015-01-01 -ls -exec rm -f {} \;
read more

centos /dev/md127 problem after reboot

Hello Well today I want to explain about my raid experience. I have to setup a hybrid server on hetzner. I setup the ssd on raid1 using installimage and those other hard drive I have create a raid from linux and mounted them on /raid1 directory . However after reboot, my /dev/md4 disappear and a /dev/md127 appear. To create the raid I have use this fdisk /dev/sdc and /dev/sdd . Make a primary partition and set it up as fd software raid partition . mdadm –create /dev/md4 –level=1 –raid-devices=2 /dev/sdc1 /dev/sdd1 mkfs.ext4 /dev/md4 mkdir /raid1 mount /dev/md4 /raid1 And insert this into fstab file /dev/md4 /raid1 ext4 noatime,rw 0 0 So how to fix this ? First I try to input some information into /etc/mdadm.conf but without luck . It appear that the linux read this late and the centos/ubuntu initalize this from initrd . So in order to fix this some steps have to be done . After reboot try to fill the information into mdadm.conf with ARRAY /dev/md/4 UUID=b3c33fe5:3b078681:e2776e37:4f9fd991 The UUID I have taken from mdadm –detail /dev/md4 First unmount and stop the raid mdadm –stop /dev/md127 After this assemble it again with your desire mdadm –assemble /dev/md4 /dev/sdc1 /dev/sdd1 After this I have copy the /boot/initramfs-2.6.32-573.3.1.el6.x86_64.img to a backup file ( initramfs-2.6.32-573.3.1.el6.x86_64.img-back ) in case something go wrong. After this run dracut –force If is centos 5 or less you have to copy initrd file and to recreate use mkinitrd -f -v /boot/initrd-$(uname -r).img $(uname -r) On ubuntu you have to run sudo update-initramfs -u And restart the...
read more

« Previous Entries