Posts Tagged ‘bg’
Tuesday, October 4th, 2022 How to install Viber client on Debian GNU / Linux / Ubuntu / Mint in 2022 and enable Bulgarian language cyrillic phonetic keyboard
So far I've always used Viber on my mobile phone earlier on my Blu H1 HD and now after my dear friend Nomen give me his old iPhone X, i have switched to the iOS version which i find still a bit strangely looking.
Using Viber on the phone and stretching for the Phone all day long is really annoying especially if you work in the field of Information technology like me as System Administrator programmer. Thus having a copy of Viber on your Linux desktop that is next to you is a must.
Viber is proprietary software on M$ Windows its installation is a piece of cake, you install confirm that you want to use it on a secondary device by scanning the QR and opening the URL with your phone and you're ready to Chat and Viber Call with your friends or colleagues.
As often on Linux, it is a bit more complicated as the developers of Viber, perhaps did not put too much effort to port it to Linux or did not have much knowledge of how Linux is organized or they simply did not have the time to put for enough testing, and hence installing the Viber on Linux does not straight supported the Bulgarian traditional cyrillic. I've done some small experimentation and installed Viber on Linux both as inidividual package from their official Linux .deb package as well as of a custom build flatpak. In this small article, i'll put it down how i completed that as well as how managed to workaround the language layout problems with a simple setxkbmap cmd.
How to install Viber client on Debian GNU / Linux / Ubuntu / Mint in 2022 and enable Bulgarian language cyrillic phonetic
1.Install and use Viber as a standard Desktop user Linux application
Download latest Debian AMD64 .deb binary from official Viber website inside some dir with Opera / Chrome / Firefox browser and store it in:
hipo@jericho: ~$ cd /usr/local/src
Alternatively you can run the above wget command, but this is not the recommended way since you might end up with Viber Linux version that is older.
hipo@jericho: ~$ sudo wget http://download.cdn.viber.com/cdn/desktop/Linux/viber.deb
hipo@jericho: ~$ su – root
1.2. Resolve the required Viber .deb package dependecies
To resolve the required dependencies of viber.deb package, easiest way is to use gdebi-core # apt-cache show gdebi-core|grep Description-en -A4 Description-en: simple tool to install deb files gdebi lets you install local deb packages resolving and installing its dependencies. apt does the same, but only for remote (http, ftp) located packages. # apt-get install gdebi-core … # apt-get install -f ./viber …
1.3. Setting the default language for Viber to support non-latin languages like Cyrillic
I'm Bulgarian and I use the Phonetic Traidional BG keyboard that is UTF8 compatible but cyrillic and non latin. However Viber developers seems to not put much effort and resolve that the Bulgarian Phonetic Traditional keyboard added in my Mate Desktop Environment to work out of the box with Viber on Linux. So as usual in Linux you need a hack ! The hack consists of using setxkbmap to set supported keyboard layouts for Viber US,BG and Traditional Phonetic. This can be done with above command:
setxkbmap -layout 'us,bg' -variant ' ,phonetic' -option 'grp:lalt_lshift_toggle'
To run it everytime together with the Viber binary executable that is stored in location /opt/viber/Viber as prepared by the package developer by install and post-install scripts in the viber.deb, prepared also a 3 liner tine script:
# cat start_viber.sh
#!/bin/bash
cd /opt/viber; setxkbmap -layout 'us,bg' -variant ' ,phonetic' -option 'grp:lalt_lshift_toggle'
./Viber

2. Install Viber in separated isolated sandbox from wider system
Second way if you don't trust a priorietary third party binary of Viber (and don't want for Viber to be able to possibly read data of your login GNOME / KDE user, e.g. not be spied by KGB 🙂
For those curious why i'm saying that Viber is mostly used mainly in the ex Soviet Union and in the countries that used to be Soviet satellite ones for one or another reason and though being developed in Israel some of its development in the past was done in Belarus as far as I remember one of the main 3 members (Ukraine, Belarus and Russia) that took the decision to dissolve the USSR 🙂
Talking about privacy if you're really concerned about privacy the best practice is not to use neither WhatApp nor Viber at all on any OS, but this is hard as usually most people are already "educated" to use one of the two.
For the enthusiasts however I do recommend just to use the Viber / WhatsApp free GPLed software alternative for Vital communication that you don't want to have been listened to by the China / USA / Russia etc.
Such a good free software alternative is Jitsy and it has both a Web interface that can be used very easily straight inside a browser or you could install a desktop version for PC / iOS and Android and more.
An interesting and proud fact to mention about Jitsy is that its main development that led the project to the state it is now is being done by a buddy Bulgarian ! Good Job man ! 🙂
If you want to give jitsy a try in web with a friend just clik over my pc-freak home lab machine has installed usable version on meet.pc-freak.net
In the same way people in most countries with American and English free world use the WhatsApp which is a another free spy and self analysis software offered by America most likely collecting your chat data and info about you in the (US Central Intelligence Agency) CIA databases. But enough blant so to minimize a bit the security risks of having the binary run directly as a process you can use a containerization like docker to run it inside and isolate from the rest of your Linux desktop. flatpak is a tool developed exactly for that.
hipo@jeremiah:/opt/viber$ apt-cache show flatpak|grep -i Description-en -A 13
Description-en: Application deployment framework for desktop apps
Flatpak installs, manages and runs sandboxed desktop application bundles.
Application bundles run partially isolated from the wider system, using
containerization techniques such as namespaces to prevent direct access
to system resources. Resources from outside the sandbox can be accessed
via "portal" services, which are responsible for access control; for
example, the Documents portal displays an "Open" dialog outside the
sandbox, then allows the application to access only the selected file.
.
Each application uses a specified "runtime", or set of libraries, which is
available as /usr inside its sandbox. This can be used to run application
bundles with multiple, potentially incompatible sets of dependencies within
the same desktop environment.
Having Viber installed on Linux inside a container with flatpak is as simple as to adding, repository and installing the flatpak package
already bundled and stored inside flathub repository, e.g.:
2.1. Install flatpak
# sudo apt install flatpak

2.2. Add flathub install repository
flatpak is pretty much like dockerhub, it contains images of containered sandbox copies of software, the main advantage of flatpak is its portability, scalability and security.
Of course if you're a complete security freak you can prepare yourself an own set of Viber and add it to flathub and use instead of the original one 🙂
# sudo flatpak remote-add –if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
2.3. Install Flatpak-ed Viber
#sudo flatpak install flathub com.viber.Viber
Reboot the PC and to test Viber will run containerized normally issue below flapak start command:
# /usr/bin/flatpak run –branch=stable –arch=x86_64 –command=viber com.viber.Viber
! NOTE ! The Linux version of Viber is missing Backups options, exclusively the Settings -> Account -> Viber backup menus is missing, but the good news is that if you're using the Viber client
as a secondary device message client, on first login you'll be offered to Synchronize your Viber data with your 1st Active device (usually your Smart Phone). Just click on it and allow the synchronization from your phone and in a while the Contacts and message history should be on the Linux Viber client.
That's it Enjoy your Viber Sound and Video on Linux ! 🙂
Tags: audio streaming, bg, Bulgarian, Communication, cyrillic, Debian, Description-en Application, Enjoy, hipo, inside, linux?, run, sudo, system resources, use, Using Viber, video streaming
Posted in Linux, Linux and FreeBSD Desktop, Linux Audio & Video, Video Streaming | No Comments »
Wednesday, September 27th, 2017
I just tried to upgrade my Debian Wheezy 7 to the latest stable Debian Stretch 9 by not thinking too much and just changing the word wheezy with stretch in /etc/apt/sources.list so onwards on it looked like so:
cat /etc/apt/sources.list
deb http://ftp.bg.debian.org/debian/ stretch main contrib non-free
deb-src http://ftp.bg.debian.org/debian/ stretch main
deb http://security.debian.org/ stretch/updates main
deb-src http://security.debian.org/ stretch/updates main
# stretch-updates, previously known as 'volatile'
##deb http://deb.debian.org/debian/ stretch-updates main
deb-src http://deb.debian.org/debian/ stretch-updates main
I also make sure all the defined Google Chrome / Opera / Skype and Squeeze Backports repositories existent in /etc/apt/sources.list.d directory files which in my case were like so;
root@noah:/etc/apt/sources.list.d# ls
google-chrome.list opera-stable.list squeeze-backports.list
opera.list skype-stable.list
were commented out because they were producing extra apt update errors …
And afterwards ran as usual:
apt-get update
apt-get –yes upgrade
The upgrade command executed fine and a lot of packages got downloaded and reinstalled without much issue, so I thought everything would be fine and just proceeded with the attempt to finalize the distribution major release 7 to major release 9 by running:
apt-get –yes dist-upgrade
But guess what now I got some dependency errors with cron and other installed packages that depend on package versions that are not going to be installed as the apt-get tool informed me.
I tried to out-smart the dpkg dependency system and removed all the packages reporting to have a missing dependencies with a short for bash loop after duming all the problematic packages showing dependency issues with commands such as:
apt-get -f dist-upgrade >> out.txt
for i in $(cat out.txt); awk '{ print $1 }' >> to_delete.txt; done
Before proceeding further I had to manually edit few lines in a text editor to remove some of the junk left from apt-get too.
So i was brave and just removed the dependency missing packages with following other for loop:
for i in $(cat to_delete.txt); do dpkg -r –force-all $i; done
Now I was hoping that rerunning:
apt-get autoremove
dpkg --configure -a
apt-get update -f
apt-get dist-upgrade -f
would no longer complain and I would just install the removed packages in another for shell loop once every other packages gets installed.
But guess what I was wrong … the system entered into another bunch of depedency terribly issues and messed up so badly that there were at least 50 packages reporting to have a missing / broken or uninstallable deb version depedency …
I got totally Angry, I knew already from experience that just trying to jump over while skipping a major release e.g. upgrade Debian 7 to Debian 9, instead of first upgrading to Debian 8 Linux and then upgrading Debian 8 to Debian 9 have always produced the same mess but I was lame and stupid again to f**k it up and I was out of mind swearing (a truly bad habid I'm not proud of) …
So as the notebook with Linux so far was perfectly working with Debian 7 and had a tons of old installed software and I was in a state where if I restart the system it was very likely my Thinkpad r61 laptop won't boot at all, I googled around to find a solution unfortunately without any luck, so finally I used the good old and tested method to DO IT MYSELF and Find the Fix without Uncle Google's help and by God's grace I did, after experimenting a while with the aptitude package / install / remove update tool without much success, finally I find the solution to the totally messed up Debian package dependencies and it all came to a simply reverting back my /etc/apt/source.list to look like following:
# deb cdrom:[Debian GNU/Linux 7.0.0 _Wheezy_ – Official amd64 CD Binary-1 20130504-14:44]/ wheezy main
##deb cdrom:[Debian GNU/Linux 7.0.0 _Wheezy_ – Official amd64 CD Binary-1 20130504-14:44]/ wheezy main
deb http://ftp.bg.debian.org/debian/ wheezy main contrib non-free
deb-src http://ftp.bg.debian.org/debian/ wheezy main
deb http://security.debian.org/ wheezy/updates main
deb-src http://security.debian.org/ wheezy/updates main
# wheezy-updates, previously known as 'volatile'
##deb http://deb.debian.org/debian/ wheezy-updates main
deb-src http://deb.debian.org/debian/ wheezy-updates main
##deb http://www.deb-multimedia.org wheezy main non-free
#deb http://ftp.debian.org/debian/ wheezy-backports main
###deb http://ftp.debian.org/debian/ wheezy-backports main contrib non-free
##deb http://dl.google.com/linux/chrome/deb/ wheezy main
#deb http://ftp2.de.debian.org/debian-volatile wheezy/volatile main
###deb http://www.deb-multimedia.org wheezy main non-free
run of the following two depedency fix commands !!!!
aptitude upgrade –full-resolver
…
aptitude full-upgrade –full-resolver
…
After a while a Debian LinuxOS system downgrade was initated and the missing packages were found, downloaded from the correct wheezy repositories and all broken and missing dependencies packages were fixed !!! HOORAY IT WORKS AGAIN!!
Tags: aptitude, aptitude full resolve, bg, dependency, fix package problems after upgrade debian ubuntu how to, fix unfixable badly messed packages linux, How to, list, mismatch, org, release, security, system
Posted in Everyday Life, Linux Audio & Video, Linux Backup tools, Linux Package Management, Various | No Comments »
Thursday, April 3rd, 2014
POSITIVE RESULTS FOR RUSSIA DURING REIGN OF VLADIMIR PUTIN
- For last 12 years of government Putin increated Russia's budget 22 times.
- Increated warfare spendings 30 times.
- Increated GDP 12 times (by GDP Russia moved from 36th to 6th place in the World).
- Increated Russian golden reserves 48 times.
- Returned back 256 oil, petrol and other natural resources sources / mine-yards (under non-Russian government curretnly are only 3 of
- Russia's source for natural resources.
- Nationalized 65% of oil industry and 95% of gas industry.
- For a 5th consequential year 2nd / 3rd place in export of grain (just for a comparison USA is currently ranked 4th largest weed exporter). The avarage sallary of national institution employed increased 18.5 times.
- Avarage pension increased 14 times.
- Reduce of population decreased from 1.5 million per year in year 1999 to 21 000 in 2011, i.e. 71 times.
- Prohibited deputies in Government to have bank accounts in foreign banks.Prevented American attack against Syria.
- Put an end to war in Chechnya.
From January y. 2000 to present times Russian ruble rate changed from 28 Rubles per dollar to 29 Rubles per dollar – i.e. severe inflation in Russia ended.Present day Russia is a normal European country not that poor country where approimate pension was 20 dollars and where masters was the financial pyramids and the International Monatery Fund
In 1992 Eltsin cancelled completely export duty of oil products.
In 23 January E. Primakov government forced again oil taxes.
In export price of 9.5 dollars per barrel custom taxes were 2.5 euro per tone and in price 12,5 dollars per barrel 5 euro / tone.Such a minor increase in taxes produced 14 billion rubles in already empty Russian budget.
In August 1999 Eltsin assigned Putin for prime minister.
In just a month later the export taxes Putin increased duty taxes to 7.5 euro/tone and in 8 december to 15 euro/tone. Till then incomes from oil taxes has been steadily increasing and nowadays exporters calculate in national budget half of incomes origin from oil prices and export taxes.
From January to November 2007 Russian customs influxed in national budget 2.57 trillion Rubles.
Oil export takes has drastically raised incomes of citizens.This had major impact on construction business.All Russia nowadays is in reality enormous "construction yard", to illustrate from January to September 2007 375 009 homes were built occupying 34 million square meters.
Cement factories cannot satisfy local market requirements and Russia is forced to import cement from China.
Increased incomes of population led to increase in estates search, this increased apartment prices and as a consequence increased incomes from building activies.
Result is in consutriction business are invested enormous amounts of capital and a real construction boom is observed.
Another consequence of increased income was increase in demand for automobiles. Just for 2006 the quantity of demanded automobiles in Russia increased with 45% and reached 32 billion dollars with a count of sold new cars numbering 2 million. By indicator of sold new cars Russia orders on 5th place after in Europe taking place right after Germany, Great Britain, Italy and France.
Currently are being build a couple of new automobile plants, and existing ones increase production volume.
All this is consequence of increase in demand and therefore from increase in citizens income.
rn>For 10 years budets expenditure for social politics (pensions and social help) increased with 30%.
Before Putin pensions were under existence-minimum with appr. 25% and in 90th pensions were not paid at all.
Now pensions are 50% above existence-minimum and is constantly increasing.
In 2000 approximate sallary in Russia was 2223 Rubles (appr. 80 dollars).
Now approximate sallary in Russia 19174 rubles (apprx. 660 dollars).
Purchase of domestic goods for 10 years increased 10 times. Number of own automobilse increased 3 times.
Putin nationalized YUKOS, without 'making nervous' emering Russian busness in a market manner – with bankruptcy and auction. All this happened lawful, following laws adopted by democratic parliament.
The president doesn't have the right to use other means. Formal occasion for arest of Hodorkovski were taxation frauds of YUKOS. In such machinations are involved practically all large private companies and this is the reason why nobody believes that excuse. It is unbelievable. However Putin simply defended Russia's interests.
The proof for that is transmission of actives of YUKOS to national corporation "Rosneft". It would have been more righteous if this actives were just confiscated … but there are laws and Putin had just stick to them. After all the President can't go out of framework of his jurisdiction.
It can be just added that after Khodorkovsky was injailed, collectivity (incomes)of taxes of ex-actives of YUKOS increased 80 TIMES!
In y. 2004 Putin finally removed law "Agreement for Separation of Production (Separation Agreement)". This law was annexed during Eltsin's regime, in order to benefit Oligarchs (Khodorkovsky, Gusinsky, Beresovsky etc.) in order to make possible Russian oil reserves to be possessed by Western (American and British) oil corporations.
By the power of this law Russian oil and natural fields went into international jurisdiction, and therefore the money from Russian oil doesn't entered budget of Russia but influxed in Western companies.
Money from oil drills went mainly into Dutch "Shell" for covering of corporation expenses. Only after something remained from that they sold it to Russia. In 2006 Putin declared following in that connection "And now we don't get anything from them and if they increase their profit we will not receive it even in 10 years from now."
In fact to this moment Russia didn't get any money from their own oil.
After the law was removed in 2004, revenues in budeg increased from 3 to 4 times.
After cancellation of contracts for oil fields "Sakhalin-1" and "Sakhalin-2" Russia's loans to American company calculated to 700 million dollars, for that time this was too much. The whole Anglo-Saxon world pricked against Putin because of a simple reason: "UK planned to assure its oil reserves for years to come in expense of Russia – only Germany and France who didn't have a direct interest in that process kept neutral …
In 1992 – 1995 the head aparatus of Russia formed its view based on foreign advisors. All legislation from 1990's was hence written by them. In Russian country administration was working 10 000 foreign coaches. George Soros was financing writting of student history books where the Battle for Stalingrad was mentioned in only 2 pages and about the meeting between Elbe and Soviet and American soldiers (Elbe Day) in 10 pages.
: In that mournful times on pupils notebook you can see portrainst of 4 American presidents of USA.
Until this very day there are left relics from that anti-Russian propaganda but hopefully with time Putin will throw away american propaganda from education system.
But why Putin cannot immediately dismiss all this hostile to Russia clerks? The reason is simple: Constitution of Russia written under dictation of Western coaches, does not allow quick changse into it.
Nowadays the President is just one of many clerks with resticted power. Yes truly president power is a bit bigger than other clerks, but country head can't influence everything. The president can't even define his ministers, even though by law this is part of his jurisdiction.
Overfulfilment of budet in times of Putin govern allowed craetion of country Stabilization fund. Nowdays is collected huge golden-currency reserve and practically Russia doesn't have external debt.
War in Kavkaz is over, separatists were destroyed. All famous terrorist leaders were liquidated physically.
Even Zelimkhan_Yandarbiyev was killed in Qatar, Basaev and Umarov were also destoyed. Putin promised "to drawn them if necessary even in their own toilet dish" and he fulfilled his promise. Of course, separatism is not completely destroyed, such conflicts cannot be quickly solved, but nowadays situation in Kakvaz is the best possible. If Chechnya's elite feels the power of Moscow and benefits of being a surrender – then separatism will fade away. This is exactly what happens. The attempts of western spy centrals to supply terrorists are still leading to separate terr. acts but this is the maximum – there will be no war anymore.
For 10 years Putin increased political influence of Russia in world and lifted its image. Today Russia follows its own interests, and not Western ones.
It is not coincidence that Putin was recognized as the most influential world politic of 2013. He prevented Russia's devastation led country out of catastrophe caused by Gorbachov and Eltsin. That's the rason why Western Medias abhor him and compare him with devil.
Everyone interested in political life in Russia seems, that the battle against corruption took unforeseen measures.
At least 2-3 times weekly on TV are shown arrests of clergy and policeman and news inform about sentences against government employees.
Lets not forget Crimea, here is how it was given to Ukraine.
In 1992 on signature of Treaty of Belovesh for dissolution of USSR Ukrainian representative Leonid Kravchuk noticed that Boris Eltsin is "in play with Vodka" and is delaying signature, he urged him with words: –
"Borya if you like take Crimea, please just sign the contract!".
Drunk Eltsin nobly waved hand:
"What for I need Crimea? Here it is your present!"
And signed and by one scratch he "killed" efforts of Prince Grigory Potemkin, Catherina the Great, heros of Sevastopol in 1856, heroes defenders of Sevastopol in 1941 …
Few days ago Putin removed consequences of this "joke with history" – and people of Crimea sung and danced on squares, returning to their motherland.
Here is Why Russophobes hates Putin!
Source Materials from http://rublogers.ru
Translated by: Georgi Georgiev
This translation is copyrighted and copying can only be done with explicit allowance of author Author or link to original translation
http://rublogers.ru/
Tags: American, avarage, bg, blog, consequence, consequences, consequential, country, devil, Dutch Shell, end, euro, existence, export, germany, heroes, Increated Russian, industry, International Monatery Fund, jurisdiction, ldquo, Leonid Kravchuk, market, meeting, mine, place, power, Prevented American, price, reason, Returned, right, ru, russia, Russian, Shell, simple, student, toilet, USA, ussr, Vladimir Putin, year, YUKOS
Posted in Curious Facts, Everyday Life, Various | 1 Comment »
Thursday, December 19th, 2013
I was stunned today to find out my countryland Bulgaria is 2nd in Europe and 5th in the world in terms of most attractive outsourcing destination according to BTA (Bulgarian News Agency).
Bulgaria is ordering 5th after, India, Indonesia, Estonia and Singapore. The ranking of most attractive destination is based on factors;
- General Competitiveness of Labor cost Worldwide
- Eligibility of Workhand
- Multilingual English speaking population (mainly young people)
- Expertised highly educated people
- Very Low Taxes (if compared to "developed" European countries)
- Decreased transportation costs (produc transportation to Europe is generally cheap)
- Internet bandwidth speed and high bandwidth connectiveness to worldwide Trade Markets
All this opens a big opportunity for economy development and inflush of fresh-money from outsourced jobs. Due to higher and European standard level of education in Bulgaria, the workhand pool in Bulgaria is usually more knowledgeable and better in quality if compared to rest of 3rd world countries India, Indonesia, Sinagopore etc. Bulgaria has generally good infrastructure and offers easy transportation of people and resources, something not so well developed yet in lets say India or Indonesia. Therefore opportunities for further development in Bulgaria as a leading outsource center in Europe are immerse in the coming 10 years. So far big companies who already realized the great Bulgaria potential like Comverse, HP, IBM etc. started actively hire people in Bulgaria and outsource their businesses but this mainly happens in Sofia.

The trend in long run however is that European leading companies start outsource in smaller cities and towns as well. Right now most prepared personal ready for outsourcing in Bulgaria is in field of Information Technologies, Electronics, Marketing, Transportation Equipment, Business Management, Chemical Industry, Food & Bevarage and Logistics. General outsourcing trend is more and more people working in not high qualitified labor to enter the market of out-sourcing. There are plenty of companies already in Bulgaria involved in textile (clothes) industry offering their cheap and high quality workhand to large external multinational companies like Zara, H & M , Versace etc.
Currently Bulgaria is considered the poorest countries in the European Union with the shocking minimal wage of 310 leva about (155 EUR) and avarage monthly sallary of 812 leva (406 EUR) monthly. The cheapness of Bulgaria is still unidentified gold field ignored by many Western Multinational companies. Outsourcing in Bulgaria has great advantages for European Countries based companies in terms of product logistics as product transportation cost and taxation within the European Union are very cheap if compared to rest of top non-EU outsourcing countries. Due to оbviously advantegous conditions in Bulgaria there are plenty of companies in Bulgaria already specialised in auditing outsourcing business risks and planning steps a company could partake to outsource its business in BG. Current Bulgarian government is making further attempts to relieve country's conditions to attract new business investors by 'Simplifying country's business registration and operations administration requirements and fostering better business environment' as said recently by second minister of economics Krasin Dimitrov in recent business forum "Opportunities and Challanges in Business Process Outsourcing (BPO) and Shared Service Centers (SSC) in Bulgaria"
Tags: bg, bulgaria, Bulgaria Top, Bulgarian, Business Management, company, destination, development, Estonia, europe, hp, ibm, India, Information Technologies, list, registration, second, speed, Trade Markets, Transportation Equipment, World
Posted in Business Management, Curious Facts, Everyday Life, Various | No Comments »
Monday, December 12th, 2011 One of the Debian servers’s SSH daemon suddenly become inaccessible today. While trying to ssh I experienced the following error:
$ ssh root@my-server.net -v
OpenSSH_5.8p1 Debian-2, OpenSSL 0.9.8o 01 Jun 2010
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: Applying options for *
debug1: Connecting to mx.soccerfame.com [83.170.104.169] port 22.
debug1: Connection established.
debug1: identity file /home/hipo/.ssh/id_rsa type -1
debug1: identity file /home/hipo/.ssh/id_rsa-cert type -1
debug1: identity file /home/hipo/.ssh/id_dsa type -1
debug1: identity file /home/hipo/.ssh/id_dsa-cert type -1
...
Connection closed by remote host
Interestingly only the SSH server and sometimes the mail server was failing to respond and therefore any mean to access the server was lost. Anyways some of the services on the server for example Nginx continued working just fine.
Some time ago while still working for design.bg – web development company, I’ve experienced some similar errors with SSH servers, so I already had a clue, on a way to work around the issue and to secure myself against the situation to loose access to remote server because the secure shell daemon has broken up.
My work around is actually very simple, I run a secondary sshd (different sshd instance) listening on a different port number.
To do so I invoke the sshd daemon on port 2207 like so:
debian:~# /usr/sbin/sshd -p 2207
debian:~#
Besides that to ensure my sshd -p 2207 will be running on next boot I add:
/usr/sbin/sshd -p 2207
to /etc/rc.local (before the script end line exit 0 ). I do set the sshd -p 2207 to run via /etc/rc.local on purpose instead of directly adding a Port 2207 line in /etc/ssh/sshd_config. The reason, why I’m not using /etc/ssh/sshd_config is that I’m not sure if using the sshd config to set a secondary port does run the port under a different sshd parent. If using the config doesn’t run the separate ssh port under a different server parent this will mean that once the main parent hangs, the secondary port will become inaccessible as well.
Tags: bg, clue, com, company, config, configuration data, doesn, exit, file, hipo, host, instance, mail server, mx, nginx, number, openssl, parent, port 22, reason, remote server, root, RSA, script, secure shell, server, Shell, shell daemon, soccerfame, ssh port, ssh server, ssh servers, sshd daemon, time, type, usr, web development company, work
Posted in FreeBSD, Linux, System Administration | No Comments »
Friday, October 21st, 2011 I needed to convert a file which had a Bulgarian text written in UTF-8 encoding to Windows CP1251 in order to fix a website encoding problems after a move of the website from one physical server to another.
I tried first with enca – ( detects and convert encoding of text files from one encoding to another).
The exact way I tried to convert was:
linux:~# enca -L bg /home/site/www/includes/utf8_encoded_file.php
...
Unfortunately this attempt to conver was unsucesfully, and the second logical guess was to use iconv – Convert encoding of given files from one encoding to another to do the utf8 to cp1251 conversion.
I reached for some help in irc.freenode.net, #varnalab channel and Alex Kuklin helped me, giving me an example command line to do the conversion.
iconv winedows to cp1251 conversion line, he pointed to me was:
linux:~# iconv -f utf8 -t cp1251 < in > out
Further on I adapted Alex’s example to convert my utf8_encoded_file.php encoded Bulgarian characted to CP1251 and used the following commands to convert and create backups of my original UTF8 file:
linux:~# cd /home/site/www/includes
linux:/home/site/www/includes# iconv -f utf8 -t cp1251 < utf8_encoded_file.php in > utf8_encoded_file.php.cp1251
linux:/home/site/www/includes# mv utf8_encoded_file.php utf8_encoded_file.php.bak
linux:/home/site/www/includes# mv utf8_encoded_file.php.cp1251 utf8_encoded_file.php
Tags: alex, attempt, bg, bulgarian text, cd home, command, conver, conversion, Convert, enca, file, file linux, freenode, gnu linux, guess, help, home, iconv, includeslinux, line, Linux, lt, move, mv, order, outFurther, php, physical server, UTF, varnalab, way, www
Posted in Linux, System Administration, Various, Web and CMS | No Comments »
Saturday, August 27th, 2011 Yesterday, most of the time I’m playing around with Squirrelmail, finally, time came when I had enough free time to fix the squirrelmail installed on mail.www.pc-freak.net
The installed version there has been broken after upgrade of the Apache webserver on the FreeBSD and failed with some stupid preg_match exception immediately after a user tries to login, anyways I decided to not install the squirrelmail from freebsd ports but rather download it directly from squirrelmail.org .
Installation went smoothly, however after testing to send email typing the email in Bulgarian with a default charset of (UTF-8) set from the Desktop machine from which I’ve written it, suddenly the sent emails encoding ended garbled.
One of my employees complained about receiving emails which are unreadable thus I proceeded immediately to check and fix the webmail letters encoding.
My logical first assumption was that the problem is caused by the FreeBSD missing a correct locale, thus the first thing I did in order to isolate the problem was check the installed locales:
pcfreak# locale -a | grep -i UTF-8|wc -l
56
As the above command output shows an UTF-8 locales was installed so I further checked if a specific locale for Bulgarian UTF-8 – bg_BG.UTF-8 is installed on the system:
pcfreak# locale -a |grep bg_BG.UTF-8
bg_BG.UTF-8
Being sure that the bg_BG.UTF-8 is installed I excluded missing locales as a possible problem cause.
Next I’ve noticed that locale command returns a default setting for my root and users set to:
pcfreak# locale
LANG=en_US.ISO8859-1
LC_CTYPE="C"
LC_COLLATE="C"
LC_TIME="C"
LC_NUMERIC="C"
LC_MONETARY="C"
LC_MESSAGES="C"
LC_ALL=
Obviously the en_US.ISO8859-1 is not compatible with UTF-8, so I had to change a consult with the FreeBSD handbook suggested a way to change the LANG and LC_COLLATE locale set variables by creating a ~/.login_conf inside the user home directory which default locale has to be set.
In my case I assumed that possible the improper LANG is set to the running Apache as Apache is run via the init script /usr/local/etc/rc.d/apache2 , therefore to work it around for apache either I had to add manually:
LANG=bg_BG.UTF-8
somewhere near the beginning of the Apache init script, or alternatively set a proper .login.conf inside the root user home dir, e.g. /root/.login.conf. An example file which sets the default locale for the root user on BSD to LANG=bg_BG.UTF-8 , is shown below:
pcfreak# cat /root/.login_conf
me:
:charset=UTF-8:
:lang=bg_BG.UTF-8:
To fix the default encoding to be set to bg_BG.UTF-8 in all shell user accounts existing on pc-freak, I used a small script which copies the /root/.login_conf to all /home directories and immediately after chowns the user to be owned by the respective user, here is bash one liner script used:
pcfreak# cd /home; for i in $(echo *); do cp -rpf /root/.login_conf $i/; chown $i:$i $i/.login_conf; done;
Now after relogging to all active shells the default LANG character setting and LC_COLLATE were changed and I could see this by issuing again the locale command:
pcfreak# locale
LANG=bg_BG.UTF-8
LC_CTYPE="bg_BG.UTF-8"
LC_COLLATE="bg_BG.UTF-8"
LC_TIME="bg_BG.UTF-8"
LC_NUMERIC="bg_BG.UTF-8"
LC_MONETARY="bg_BG.UTF-8"
LC_MESSAGES="bg_BG.UTF-8"
LC_ALL=
To make sure the apache is reading the new LANG locale settings, further on I forced apache restart:
pcfreak# /usr/local/etc/rc.d/apache2 restart
I opened a browser and sent one more mail typed in cyrillic with squirrelmail addressing my own email to test, if finally the mail char encoding issues are gone. But NOO!! still the same issue.
I was out of ideas as it seems there was no logical reason for the cyrillic letters to break when sent via squirrelmail.
And then the lightbulb was up with the idea to check the squirrelmail configuration encoding itself, thus I launched immediately the squirrel ./configure script and guess what, the encoding there was also imroperly SET to en_US.ISO8859-1!
pcfreak# cd /var/www/webmail; ./configureSquirrelMail Configuration : Read: config.php (1.4.0)
----------------------------------------
Main Menu --
1. Organization Preferences
2. Server Settings
...
8. Plugins
9. Database
10. Languages
Command >> 10
SquirrelMail Configuration : Read: config.php (1.4.0)
----------------------------------------
Language preferences
1. Default Language : eu_US
2. Default Charset : en_US.ISO8859-1
3. Enable lossy encoding : false
Command >>
To change the encoding to properly play with Bulgarian, cyrillic in UTF-8 I choose:
Command >> 1
SquirrelMail attempts to set the language in many ways. If it
can not figure it out in another way, it will default to this
language. Please use the code for the desired language.
[en_US]: bg_BG
Command >> 2
SquirrelMail attempts to set the language in many ways. If it
can not figure it out in another way, it will default to this
language. Please use the code for the desired language.
[en_US.ISO8859-1]: bg_BG.UTF-8
Finally to save the new settings into squirrelmail configuration used the S cmd:
Command >> S
...
And Hallelujah! My Bulgarian letters started being properly encoded and sent in squirrelmail 😉 thx God
Tags: apache webserver, assumption, bg, charset, code, collate, config, configure, CTYPE, default locale, Desktop, desktop machine, download, exception, free time, freebsd handbook, freebsd ports, grep, home directory, init, installed version, ISO, lc, login, machine, mail, MONETARY, numeric, pcfreak, php, preg, root, script, Squirrel, thislanguage, time, time c, utf 8, webmail
Posted in Linux, Linux and FreeBSD Desktop, System Administration, Web and CMS | 1 Comment »
Tuesday, March 3rd, 2009
On Tuesday Zlati (A friend of mine introduced to me by Father Veliko), came to Arnhem. The plan was that he came on Tuesday here and afterwards in Wednesday morning the Trip to Amsterdam was going to happen. First we had settled that he will be in Arnhem in 12:00 o’clock. So Around 10:50 I walked down the way to the trainstation. I was on my way when Zlati ringed and told that he still, haven’t catched the train and he is not going to make it for 12:00, though he will be on Arnhem Central Station in 04:35 in the afternoon. I came back to home and on my way bought some apples as well as a oily sweet thing from the Turkish shop “Sultan” 🙂
Around 3 I took my way to the city center again, on my way I had toleave Sali’s laptop in his home. I had taken his laptop to re-install Windows and setup his Windows in Bulgarian as well as configure it to be able to watch Bulgarian TV channels online.
In order to achieve that I used a proxy donated to me by Amridikon. Thanks Amri!
To make Windows Vista Home Premium to Bulgarian I had to use a small proggie “Vista Change Language 1.0”. I had to burn the program to a CD and boot into it and then use the downloaded language pack to change the vista text language to Bulgarian. I did so all went well, unfortunately after an upgrade the text in the menus did screw up. So I have to boot again in the Vista Change Language 1.0 boot CD and revert it back to Bulgarian.
Then I had to disable Windows Vista updates in order to prevent the same language mess up to occur again. This was a little out of the topic, but I decided it’s nice to have it on paper.
So back to where I was with my TTA .. I took Zlati from the train station,we went to Sali and he treated us with some kind of traditional turkish soup meal. The soup was quite nice btw. He was extremely happy that he could watch Bulgarian TV’s online through the bg.gledai.tv website. I was glad to that God helped me and blessed me in succeeding in all the things I mentioned above. Afterwards we went with Zlati and Koko to Albertheijn picked up a beer and a couple of other things. Then I and Zlati went to my place where we used my notebook to research about places of Interest, we would like to attend in Amsterdam. We went to bed around 2 o’clock at night.
At the morning we went to the train station. I suggested that we go a little earlier because I thought, well it might be better to be earlier in the city for to have more time to walk and take a look at its significant things in it. We were on the train station 8:10 and had the intention to take the first train at 8:29, however God had other plans for that.It seemed that we have to wait and buy a ticket for after 9:00, otherwise Zlati couldn’t use his train card for my discount.He was quite irritated by the fact that I suggested that we went to the train station so early since he was quite sleepy in the morning because we went to bed so late.
Anyways I got a coffee from the trainstation waiting-room coffee machine.And, eh the coffee there is expensive, be careful if you travel in the Netherlands by train.
The coffee costed 1.50 per cappuchino, huh … We catched a train in 9:29 and we were in the capital of Amsterdam in 10:40.
I was so excited! Yes the trip worthed the price of 16.30 EUR (with the 40% discount). Amsterdam is a really nice city, especially considering it’s architecture. And I saw such a big shops and so many things to choose from … The whole city is full of canals and boats are traveling through it.
We went to music store, wow there was so much music in it.
We entered a lot of Catholic Churches in one of the Catholic Churches there was an orthodox icon of St. Nickolas! So I made the sign of the cross and prayed the Saint to pray God for me the sinner.
With our arrival right after we went out of the central station I saw a bookstore,so I proposed Zlati to enter. It seemed that was a protestant Christian bookstore. Even though a protestant one the people there at least were believing in our Lord and Saviour Jesus Christ.
I had a small chat with one of the guys asking if they have Orthodox Bible, It seemed they haven’t so I started telling him about the advantages of being Orthodox Christian. I explained him how I became orthodox after God gave me the faith and transformed my life.
The bookstore had a free/coffee and tea.So each me and Zlati took a cappuchino. It was so nice God gave me a hot drink in the Early morning in Amsterdam.
A lot of people are insane in that place, I saw a lot of pod smokers on the street.
On a lot of places the air had that typical pod stell. We saw a lot of Museums, we tried to use a citymap although in a lot of cases un-succesful. We saw so many Churches, Madam Tusad’s museum,as well as Anne Frank museum, the tulip museum.
There was also sex, museums we saw on our way and even this freaks had gay museum. We saw some road building in progress where a couple of people were building a road on top of pillars, right above the water! 🙂 The city is full of old buildings most of which originating from 16th century. The Architecture is really amazing. The parks and everything and the terraces had that typical European style which I’ve seen in movies showing people from the 18thor 19th century drinking coffees on the balconies. We took a lot of pictures. Unfortunately I still haven’t taken the pictures from Zlati. We entered into a shop which was selling buddhist, hindu and indian statues and souvenirs to warm a bit as the weather outside was coldy.
There we had a nice chat with the storekeeper, about religion and about my Orthodox faith in Our Lord Jesus! He mentioned that near around there is an Syrian Orthodox Church. So went to seek for it. After some rambling we found it but unfortunately it was already closed the time was quite late over 18:00, so it was quite normal to be closed.The style of the Church didn’t really much differentiated from the rest of the Catholic Churches.
Earlier we went into a Church, whether they had that modern exposition, again we went their to warm ourselves (it was such a cold day).
The Church inside was nice but the pictures,they was selling on the expo was really terrible, a lot of sado-mazo and perverted motives in the pictures …
I was saddened to see that they have de-sacrated a holy place like that. Well it’s true that the Roman catholics stepped aside from the orthodox faith some time ago but still they are believing Christians and therefore there temples are holy to some degree too … therefore such an abomination really shouldn’t happen.
The good thing was that in the Church they even had made toilets inside the church we could use 🙂
The Church wall paintings were displaying the way our Lord Jesus has walked on it’s way to final execution by the jews, carrying his cross on the way to Golgotha.
Around 18:30 we went to the street where the so famous prostites and drug addicts street was the “RED LIGHTS” – so famous all around the world ….
I couldn’t believed my eyes, prostites staying behind windows half naked waiting for a customer to hire them for sex …I have heard about that place but I really couldn’t imagine it could legally exist in the center of a metropolitan city like Amsterdam.
We walked in that “wicked” part of the city for around hour.
There were all kind of junkies people who looked really criminal, the prostitutes on the windows. Sex shops, sex video rooms, you name it .. all the disgusting stuff you could imagine. After this walk we went to the train station around 8:00 and took the train back to Arnhem. The whole day went quite flawless,God has heard our prayer to keep us from evil and give us safe journey.The whole trip was really relaxing for me! Praise the Lord for his great mercy towards me the sinner for giving my eyes to see all this things!
Tags: apples, bg, bookstore, boot cd, cappuchino, Catholic, center, change language, city, configure, Father, language pack, laptop, menus, Pack, place, pod, proggie, protestant, proxy, quot, Sali, screw, shop, sultan, sweet thing, text, text language, train, train station, trainstation, Trip To Amsterdam (TTA), TTA, tv channels, tv website, Veliko, Wednesday, wednesday morning, windows vista home premium
Posted in Everyday Life | No Comments »
Monday, February 16th, 2009 Saturday was quite shaking. The morning start yearly around 8:30.Anton a friend of mine for whom I am working and for whom I am admining twoservers. Called yearly in the morning and informed me that winner.bg is not working for several hours. I logged on the server and tried to see what’s wrong.It seemed that the whole MySQL was quite messy. It even refuses to start.There were corrupted data the system seemed to be restarted twice.I won’t enter into much details here just put some moral mostly.I was desperate things looked like everything was lost. The old sqlbackups made by the automated script I use were completely useless causethey were dumped with characterset latin1 …. So everything which was in cp1251appeared like “?” questionmarks. I thought there was encoding problem and the problem might be solved with iconv, however unfortunately that was not the case.The dumps were completely useless. So as a prescription if you use cp1251 or koi8r or any cyrillic encoding and you’ve explicitly definition in /etc/my.cnfoutlining that be sure not to dump with –default-character-set=latin1 ! Never ever! do this. At a moment I felt completely forgotten by God doubt came along for a second, nevertheless I started praying even though only with hope and without faith enough I screamed “Lord Jesus Christ, Son of the Blessed God, have mercy on me the sinner!”. Eventually until 16:45 most of the problems were fixed. Praise the Lord! Hallelujah! I could see one more time clearly God fixing things for me. To be honest I was so messed at a poing before all came to its place that I was not knowing exactly what I am doing. I followed a couple of steps one of which was completely unsinstall the mysql server and exchange it with 5.0.75 from 5.0.65. I had to switch to innodb recovery mode level 4 and dump some of the databases and import them back. A lot of the databases I simply copied in binary format to the newly created sql server. The sql server started working again ! Blessed be God My helped and refugee! I did some shopping on Saturday 5:30 ’till 18:00. Then I tried to recover the databaess with the screwed cyrillic letters. I had to contact ganchev “shudder” a friend of mine who is pretty good in coding and worked at the same company I did for some years. He couldn’t help however he advised me to check the dumps with hexdump -C and see if the “?” questionmarks are questionmarks. In my case they were so the backups were completely useless. I was lucky that one of the database my friend Tony has backed up and the other one was for a website who was started just a few days before so data there could be recovered with a little effort and it’s not gonna be so fatal I guess. Later on during the evening I updated a couple of services like apache php eaccelerator and so on on the two freebsd servers I take care for. On the Sunday morning I had to fix a little thing a consequence from the nightly update. The php5-gd port didn’t upgraded with the portupgrade -ri cause according to portaudit it has a security flaw. However quite flashy and luckily I fixed the problem. The rest of the Sunday I spend in talks with Paco, then we went to Sali and went to Lumiere the coffee restaurant where Sali managed to arrange work for Papi. The idea of us going there was to negotiate if possible to increase Papi’s daily sallary cause today he receives only 20 EUR per day for 10 hours of work. We went to Lumiere with Bikes that Sali gave us. On our way Papi fall off his bike and hurt his leg badly … 🙁 We went there and drinked coffee, thanks God they didn’t charged me for the coffee because the restaurant owners (Aidyn and Tazira) said the coffee I don’t need to pay for. After that we went back home we had small argue with Papi for which I deeply regret. I should thanks God for granting me from his divine mercy and doing so much for me the sinner. Quite in a few minutes I’ll be praying a bit and going to bed. Let’s hope that the Lord will be blessing me and helping me in my work and studies in the coming week just like he did so far. Just to conclude my post. Glory be to you Almighty and all merciful Lord my stronghold and my refugee! Hallelujah!END—–
Tags: action, bg, cause, characterset, coffee, corrupted data, databases, default character, doubt, dumps, everything, faith, god have mercy, Hallelujah, iconv, jesus christ son, level, lord jesus christ, Lumier, mysql server, php, place, poing, Praise, quot, recovery mode, Sali, second, sinner, time, winner, work, yesterday
Posted in Everyday Life | No Comments »
Thursday, January 31st, 2008 Tell me which ideotic government would create a site based on php and would make the serverunder Windows?
Just Guess ours the Bulgarian ministry of Science and Knowledge has started a new site dedicated to helping graduating school pupils with the Future School-examinationthey have to make.
It’s pretty easy to see that just observe:
jericho% telnet zamaturite.bg 80
Trying 212.122.183.208…
Connected to zamaturite.bg.
Escape character is ‘^]’.
HEAD / HTTP/1.0HTTP/1.1 200 OK
Connection: close
Expires: Thu, 19 Nov 1981 08:52:00 GMT
Date: Wed, 30 Jan 2008 19:10:18 GMT
Content-Type: text/html; charset=UTF-8Server: Apache/2.2.6 (Win32) PHP/5.2.5X-Powered-By: PHP/5.2.5Set-Cookie: PHPSESSID=fn5jtjbet7clrapi0a5e5kgvt7; path=/
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
Keep-Alive: timeout=5, max=100
Connection closed by foreign host.
jericho%
Just great our Bulgarian government spend money on buying proprietary software OS to run a Free Software based solution.
This example is pretty examplary of what our country looks like. Sad …
END—–
Tags: Alive, apache 2, bg, bulgarian government, Cache, cache control, charset, content type, Cookie, Date, Expires, Free, free software, future school, government, HEAD, host, HTTP, jtjbet, knowledge, money, php, php 5, proprietary software, school pupils, science, server, Set, software, text, text html, UTF, zamaturite
Posted in Everyday Life, Various | No Comments »