Emir Halilzade

Emir Halilzade

(2 comments, 82 posts)

This user hasn't shared any profile information

Home page: http://www.halilzade.com

Posts by Emir Halilzade

Linux Plesk Postfix 587 Ayarı



Centos plesk panel kurulu sunucunuz üzerinde postfix mail servisini kullanıyor ve eğer outlook üzerinde mail gönderirken hata alıyorsanız aşağıdaki işlemleri yaparak sorunu çözebilirsiniz.

SSH bağlanın.

# nano /etc/postfix/master.cf

submission inet n – n – – smtpd -o smtpd_enforce_tls=yes -o smtpd_tls_security_level=encrypt -o smtpd_sasl_auth_enable=yes -o smtpd_client_restrictions=permit_sasl_authenticated,reject -o smtpd_sender_restrictions=

encrypt değerini bularak aşağıdaki şekilde değiştirin.

submission inet n – n – – smtpd -o smtpd_enforce_tls=yes -o smtpd_tls_security_level=may -o smtpd_sasl_auth_enable=yes -o smtpd_client_restrictions=permit_sasl_authenticated,reject -o smtpd_sender_restrictions=


Centos Dosya Silme İşlemleri


Disk Üzerinde Yer Açma
tune2fs -m 1 /dev/sda3

Klasör boyutlarını listeleme (Ana Dizin)
cd /
du -sh ./*

Klasöre girerek dosya boyutlarını görme
cd /<suspiciously large dir>
du -s ./* | sort -n


Exchange 2010 OWA beyaz sayfa


Exchange server 2010 üzerinde bazen servislerin durması hatalar ile karşılaşmanıza neden olabiliyor.

Bunlardan birisi de Exchange 2010 OWA üzerinden giriş yaptığınız zaman beyaz sayfa göstermesidir (blank page, boş sayfa)

Bu hatanın çözümü ise oldukça basittir.

Exchange 2010 OWA beyaz sayfa hatasını ise "Microsoft Exchange Forms-Based Authentication Service". servisini başlatmanızdır.



Creating a static copy of a dynamic website


Creating a static copy of a dynamic website

At work we have several websites that we develop with Plone, but each year we make a new version and we want to keep an archive of the old version.

Since it takes a lot of memory to keep a Zope instance for these old websites that probably won’t need to be edited ever again, it makes sense to make a static copy of the website. It also eliminates the work needed to update the instance when security patches come out (and eliminates security risks, in cases of old versions that are no more maintained).

There are some tools that can help in this case; I chose to use wget, which is available in most Linux distributions by default.


The command line, in short…
wget -k -K  -E -r -l 10 -p -N -F –restrict-file-names=windows -nH http://website.com/

…and the options explained

-k : convert links to relative
 -K : keep an original versions of files without the conversions made by wget
 -E : rename html files to .html (if they don’t already have an htm(l) extension)
 -r : recursive… of course we want to make a recursive copy
 -l 10 : the maximum level of recursion. if you have a really big website you may need to put a higher number, but 10 levels should be enough.
 -p : download all necessary files for each page (css, js, images)
 -N : Turn on time-stamping.
 -F : When input is read from a file, force it to be treated as an HTML file.
 -nH : By default, wget put files in a directory named after the site’s hostname. This will disabled creating of those hostname directories and put everything in the current directory.
 –restrict-file-names=windows : may be useful if you want to copy the files to a Windows PC.

Possible problems
»  wget download the homagepage, robots.txt then stops!
 Your robots.txt file probably denies access to your site to search engines. Yes, in recursive mode, wget will respect the robots.txt file, so you will need to remove it before making the copy. Don’t forget to put it back in the static site if that’s what you want.
» Stylesheets : if you have @import stylesheet imports, wget won’t see them, and won’t download them :( You might want to change them to <link rel=”stylesheet” … /> imports, which wget will see and download.
» Stylesheet images : wget won’t download background-images referenced in CSS files. For most websites that should not be too long to download those images manually.
» Be sure that you CSS files and with “.css”! Apache won’t send the correct mime-type if your file extension is not .css, and Firefox will not use the stylesheet.
 (test.css?color=blue won’t work, change it to test.css?color=blue&ext=.css)
 The same problem may happen with other files types that need to have a proper mimetype set (video files, for instance)
» LinguaPlone specific problems »  To prevent having several duplicated files with the set_language parameter, you could setup one subdomain for each language, and force the set_language= in the Apache redirect rule.
»  I also recommand to change the language link so it points to the main page instead of the current page.
»  You have several possibilities here, but by just doing a wget without changing anything, you may end up with pages where languages are a bit fucked up.

» <base> tag problem : If you pages contains a base tag (which is true for Plone sites), wget will empty it’s value but leave the base tag there ([base href="" /]). That works in Firefox, but it will confuse IE, which won’t load any images, CSS or links.To fix it, you can remove the base tag completely with this command : find | grep html$ | xargs perl -i -p -e 's/<base href=\"\" \/>//g'

» Most file names will change (bad for SEO)
» May take some manual work to have a working static copy

After taking care of all the possible problems, you should have a working static site! Be sure to check with both IE and Firefox (at least), because some problems happen in only one browser.
 Then, you can shut down your CMS and server the static content using a standard webserver.

Don’t forget to put a nice 404 page pointing to your main page, since your URLs probably changed, and several visitors will get a 404 error if they come from search engines or bookmarks.


Alıntı : https://www.quora.com/How-do-you-export-a-WordPress-site-to-a-static-HTML

Linux Plesk Sitelerin Toplu IP Adresi Değiştirme



Kullanıcıların çok sık karşılaştığı ve bir çok hatalı durumların ortaya çıktığı plesk 'de bütün sitelerin ip adresini toplu olarak değiştirmek için aşağıdaki komut işinizi görecektir.


mysql -Ns -uadmin -p`cat /etc/psa/.psa.shadow` -D psa -e 'select name from domains' | awk '{print "/usr/local/psa/bin/domain –update " $1 " -ip <IP ADRESİNİZ>"}' | sh

Bu komutu çalıştırdıktan sonra ssh konsol ekranında sitelerin ip adresinin değiştiğini göreceksiniz. Sitelerin sayısına göre işlemin tamamlanması zaman almaktadır.

Son olarak aşağıdaki komutu çalıştırarak plesk panelin kendisine gelmesini sağlıyoruz.

cd /usr/local/psa/bootstrapper/pp11.0.9-bootstrapper/
./bootstrapper.sh repair

EK bilgilendirme olarak,

pp11.0.9-bootstrapper >> plesk sürümüne göre değişiklik gösterebilir.




WHM / cPanel Exim Mail Kuyruğunu Temizlemek


Bekleyen mail sayısını görmek

exim -bp

Bekleyen mail ID sini girerek maili silmek

exim -Mrm {message-id}

Bekleyen mailleri silebileceğiniz 1. komut

exim -bp | awk '/^ *[0-9]+[mhd]/{print "exim -Mrm " $3}' | bash

Bekleyen mailleri silebileceğiniz 2. komut

exim -bp | exiqgrep -i | xargs exim -Mrm

Cpanel SSH Support access ID Öğrenme



Cpanel 'e ticket açarken veya farklı ihtiyaçlarda kullanabilmek adına bazen whm panelinize erişemediğiniz durumlarda aşağıdaki kod ile ssh üzerinden Support access ID numaranızı öğrenebilirsiniz.


/usr/local/cpanel/cpanel -S

Esxi Sunucuları Listeleme



Vmware Esxi kurulu sunucularda bazen sorunlar yaşarız ve bütün sanal sunucuları listemek gerekebilir. Aşağıdaki komutla ile sunucuya SSH ile bağlanıp bu komutu çalıştırdığınız zaman sunucuların listesini görebilirsiniz.


esxcli vm process list

Failed to create gpg object: No keys found for vendor ‘cpanel’ Please see http://go.cpanel.net/sigerrors for further information about this error.


root@web2 [~]# /scripts/easyapache
die [cpanelsync] Failed to create gpg object: No keys found for vendor 'cpanel' Please see http://go.cpanel.net/sigerrors for further information about this error.
die [cpanelsync] Failed to create gpg object: No keys found for vendor 'cpanel' Please see http://go.cpanel.net/sigerrors for further information about this error.
Download Failed… trying again…in….60….59….58….57….56….55….54….53….52….51….50….49….48….47….46….45….44….43….42….41….40….39….38….37….36….35….34….33….32….31….30….29….28….27….26….25….24….23….22….21….20….19….18….17….16….15….14….13….12….11….10….9….8….7….6….5….4….3….2….1..die [cpanelsync] Failed to create gpg object: No keys found for vendor 'cpanel' Please see http://go.cpanel.net/sigerrors for further information about this error.



EasyApache should be working without issue now. The problem was your lot of root certificates on your server was either missing or incorrect.

I corrected the problem by running the below commands:

mkdir /usr/src/ca-certificates && cd /usr/src/ca-certificates
wget http://mirror.centos.org/centos/6/os/i386/Packages/ca-certificates-2014.1.98-65.1.el6.noarch.rpm
rpm2cpio ca-certificates-2014.1.98-65.1.el6.noarch.rpm |cpio -idmv
cp -pi ./etc/pki/tls/certs/ca-bundle.* /etc/pki/tls/certs/

Finally running the below command to update the keys for cPanel:

Best Regards,



Centos Memcached ve memcached kurulumu


wget https://github.com/downloads/libevent/libevent/libevent-2.0.21-stable.tar.gz
tar xvfz libevent-2.0.21-stable.tar.gz
cd libevent-2.0.21-stable
make install

wget http://memcached.org/files/memcached-1.4.22.tar.gz
tar xvfz memcached-1.4.22.tar.gz
cd memcached-1.4.22
make install
ln -s /usr/local/lib/libevent-2.0.so.5 /usr/lib64/libevent-2.0.so.5
memcached -d -u nobody -p 11211

wget http://pecl.php.net/get/memcache-2.2.7.tgz
tar xvfz memcache-2.2.7.tgz
cd memcache-2.2.7
make install

nano /usr/local/lib/php.ini
>> extension_dir = "/usr/local/lib/php/extensions/no-debug-non-zts-20060613" alt satırına altdaki satırı ekle
>> extension=memcache.so


Emir Halilzade's RSS Feed
Go to Top