vitich.kiev.ua was registered on Dec 15, 1999
vitich's blog
Migrate any mail server to hestiacp (vestacp fork)
Posted by vitich on Saturday, 31 August 2019My friend asked me to help with the migration of mail from a server running ispmanager5 lite to a server running vestacp. But this script is suitable for migration from any imap server to hestiacp panel.
I found imapsync utility and I'll use it. The email.txt file should contain a list of mailboxes and passwords, one account per line.
hcloud: command-line interface for hetzner cloud
Posted by vitich on Friday, 30 August 2019Create server:
hcloud server create --name=myserver --image=ubuntu-18.04 --type=cx31 --datacenter=hel1-dc2 --ssh-key=vitich
List our servers to get server ID:
hcloud server list
Add floating-ip
hcloud floating-ip create --type=ipv4 --home-location=hel1
List floating-ip to get floating-ip ID:
hcloud floating-ip list
iptables geoip too many countries specified
Posted by vitich on Wednesday, 15 May 2019Знадобилося заблокувати деякі країни однією строкою:
iptables -I INPUT -m geoip --src-cc
AR,BR,CN,CO,DZ,HK,IN,IR,KP,LA,MY,OM,PK,SC,TH,TW,VN -j DROP
Але отримав таку помилку:
iptables v1.6.0: geoip: too many countries specified
Оскільки я використовую кастомне ядро - я збираю xtables-addon самостійно.
Отже, нам потрібно збільшити XT_GEOIP_MAX та перезібрати.
wttr conky
Posted by vitich on Wednesday, 8 May 2019I have been using this weather service for several years. Almost no problems.
Add to your conky config:
${texeci 300 curl -A "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/74.0.3729.131 Safari/537.36" http://wttr.in/Kyiv_0pq_transparency=200_lang=uk.png -o $HOME/.conky/out.png}
${image $HOME/.conky/out.png -p 0,0}
Chrome kiosk on multiple monitors
Posted by vitich on Monday, 6 May 2019I have two FullHD monitors and I want to launch the browser in kiosk mode so that Google will always open on the first monitor, and Facebook on the second one.
Let's specify the position, window size and path to the browser profile.
First monitor:
skypeforlinux tray icon bug
Posted by vitich on Monday, 29 April 2019ansiweather conky
Posted by vitich on Tuesday, 23 April 2019Edit Java Security Exception list in Linux
Posted by vitich on Wednesday, 10 April 2019Якщо ви користуєтеся IP-KVM / iLO / IPMI то мабуть Ви стикалися з помилкою "java application blocked by security settings".
Вирішується достатньо просто:
echo "https://10.0.0.1" >> ~/.java/deployment/security/exception.sites
Якщо хочеться додати всі можливі адреси в локальній мережі, то робимо скрипт і додаємо свої мережі:
YELLOW status in Elasticsearch
Posted by vitich on Tuesday, 9 April 2019The status is yellow because we have unassigned shards.
In this case we have one node cluster, but our indices all have number_of_replicas: 1 (which is the default). So we have to add a second node to our cluster, or just set "number_of_replicas: 0" globally:
curl -XPUT -H "Content-Type: application/json" 'localhost:9200/_all/_settings' -d '{"index" : {"number_of_replicas" : 0}}'