Показаны сообщения с ярлыком linux. Показать все сообщения
Показаны сообщения с ярлыком linux. Показать все сообщения

вторник, 27 сентября 2016 г.

Job: Linux Administrator / DevOps Engineer, Tokyo, Japan (relocation)

Друзья, мы ищем человека себе в команду в Токио. Опыт администрирования Linux, целеустремленность, желание работать в команде и знание английского обязательны, остальному научим.

Вакансия в Токио.

понедельник, 9 марта 2015 г.

Why Linux is not yet ready for Desktop

1. Virus epidemic is still not possible on Linux
Nobody is going to care about making Linux popular until it is possible to spread viruses and trojans on it widely.

2. No nice antivirus software for Linux Desktop available
As viruses are not popular so antivirus companies do not care much about creating something good for it. What a user can trust a system without antivirus?

3. Migrating Linux to new hardware is too easy
Moving to new hardware is as simple as moving your disk drive to another system. No reinstalling software, no reconfiguration, no driver installation. How end-user support companies are going to make money on this? Thus they do not care about making Linux Desktop popular either.

4. Most of software is in on place and freely accessible
There is no software company which can keep users and make them pay without vendor lock-in. Possible with Linux? Absolutely not.

5. Spying on users is very difficult
How can companies inject spyware or adaware while most of software are coming from a distribution repository? There is on easy way. No companies like this.

6. Linux is too customizable
The more freedom to users is given, the less control of them is taken. Less control means less money. No, users do not need freedom.

7. Deep look inside is possible
Allowing looking inside is way too dangerous. What if advanced users can find some stupid bugs? What if the can fix something by themselves? What if they can copy our ideas and user them in their own projects? Users should not have access to source code and modify it. They should not even understand how it works until they purchase for a related course.

8. Encryption out of the box
Many of Linux distributions provide strong system and profile directory encryption out of the box. Neither government nor companies are interested.

Is there anybody who still think that Linux is ready for Desktop after all this? I doubt it.

пятница, 12 декабря 2014 г.

I'm adherent of Copyleft

Some time ago I had a task to choose configuration management system for our Linux machines and came to the battle between Salt and Ansible. While technically these systems are similar, licensing models are different. Salt developers chose Apache license and Ansible stopped on GPL one. As a copyleft lover I shouldn't not even think much and Ansible would be my the only choice. However I decided to dig a bit and Google what other people think.

Ideas I keep in mind when I choose software licensed by copyleft license:
- this software is open
- this software will be open forever (or at least for a long period of time)
- developers and users are motivated to contribute

And generally this works for copyleft licensed software, but this is not a rule.

Coming back to Ansible vs Salt I found Salt community extremely active, friendly and welcoming. And this is the most reliable indicator that this piece of software is going to live long and open life. And thus I choose Salt, I choose community and not the license.

Some links to the topic:
http://ryandlane.com/blog/2014/08/04/moving-away-from-puppet-saltstack-or-ansible/
http://jensrantil.github.io/salt-vs-ansible.html

пятница, 5 сентября 2014 г.

Safe work around to make check_esxi_hardware.py work within normal user

Adding nagios user to the root group (popular work around in the Internet) is a big security hole. I suggest never doing this.

Here is a better work around until VMware fixes 'CIM interaction' permission (which doesn't work at least since 4.0 and up to the recent 5.5):

1) Create a local user 'nagios' on a ESXi host
2) Add a cron job to check and update /etc/security/access.conf
user=nagios; access=/etc/security/access.conf; crontab=/var/spool/cron/crontabs/root; grep $access $crontab > /dev/null || cat << EOF >> $crontab
*/5  *    *   *   *   grep '^+:$user:sfcb$' $access > /dev/null || sed -i '2i +:$user:sfcb' $access
EOF
3) Done!

Now you can use nagios user to check check_esxi_hardware.py, no special roles or permissions are needed.

пятница, 17 января 2014 г.

Ubuntu 12.04, OCS Inventory and UTF-8

Ubuntu 12.04 ships with OCS Inventory 2.0.2, however UTF-8 patchs come later in 2.0.4. Here is a way to fix UTF-8 for 2.0.2.
 # The following changes made to OCS Inventory after installing in order to make it display UTF-8 correctly.  
 wget http://bazaar.launchpad.net/~ocsinventory-core/ocsinventory-ocsreports/stable-2.0/diff/791 -O /tmp/utf8-1.patch  
 wget http://bazaar.launchpad.net/~ocsinventory-core/ocsinventory-ocsreports/stable-2.0/diff/801 -O /tmp/utf8-2.patch  
 cd /usr/share/ocsinventory-reports  
 patch -p0 -i /tmp/utf8-1.patch  
 sed -i 's/,,/,/' backend/require/lib/phpcas/CAS.php  
 patch -p0 -i /tmp/utf8-2.patch  

четверг, 12 декабря 2013 г.

GPL is not charity

One can always hear or read something like "GPL does not mean free, it restricts some rights". And they are right. GPL is not about charity unlike many of BSD-like licences. GPL has its purposes: motivation for contribution, gathering knowledge, growing. GPL has never been supposed to be a charity. GPL is about freedom for end-users and not for developers or vendors.

понедельник, 28 октября 2013 г.

Gigaset and Polycom: convert IPUI to IPEI

ipui-to-ipei.sh:

#!/bin/bash

printf "%05d %07d\n" $((0x${1::5})) $((0x${1:5:5}))


Usage example:

$ ipui-to-ipei.sh 001bf582ab
00447 0361131


Get IPUI on Gigaset phone:

Menu -> *#06# -> first line

пятница, 25 января 2013 г.

Качаем субтитры в одно нажатие / Download subtitles in one click

Вы часто смотрите фильмы с субтитрами? Вот я, например, это дело очень люблю, но, честно сказать, я устал их искать и скачивать. Ведь хочется так, чтобы "включил и смотри". И я нашёл такой способ. Делюсь.

Вам понадобится:
- Linux (подойдёт любой, но тестировалось на Ubuntu и Arch Linux)
- Видеоплеер (в моём случае это mplayer)
- subdl - небольшая утилита, позволяющая скачивать субтитры с opensubtitles.org
- совсем немного bash-а

Готовим

Качаем и устанавливаем subdl

mkdir ~/bin
wget http://subdl.googlecode.com/svn/trunk/subdl -O ~/bin/subdl
chmod +x ~/bin/subdl

Пишем и устанавливаем небольшой скритп mplayer-sub.sh

cat > ~/bin/mplayer-sub.sh << EOF
#!/bin/bash

[[ -z "\$@" ]] && exit 0
interactive=""; if [[ "\$1" == "-i" ]]; then interactive="-i"; shift; fi

for file in "\$@"; do echo \$file; subdl \$interactive "\$file"; done
mplayer "\$@"
EOF
chmod +x ~/bin/subdl

Используем

Ну что, попробуем? Если до настоящего момента у вас не было директории ~/bin, то потребуется перелогиниться, а если же уже была, то - поехали!
mplayer-sub.sh Once.Upon.a.Time.S02E12.HDTV.x264-LOL.mp4
или так
mplayer-sub.sh ~/Video/Once.Upon.a.Time.S02E12.HDTV.x264-LOL.mp4
или да же вот так
mplayer-sub.sh ~/Video/Once.Upon.a.Time.*.mp4
В последнем примере наш скрипт скачает субтитры на английском языке (это язык по-умлочанию для subdl, разумеется можно поменять) для всех видеофайлов подпадающих под шаблон Once.Upon.a.Time.*.mp4 и затем добавит их в плейлист mplayer-а. Удобно, неправда ли? :)

 


 

Do you like to watch movies with subtitles? I do like it very much and to be honest I've got tired to download them each time. Wouldn't it better if you could just click and go? There is a way. I'd like to share.

You need:
- Linux (any Linux, but tested on Ubuntu Arch Linux)
- Movie player (it's mplayer in my case)
- subdl
- command-line tool to download subtitles from opensubtitles.org
- just a little of bash

Cook

Download and install subdl

mkdir ~/bin
wget http://subdl.googlecode.com/svn/trunk/subdl -O ~/bin/subdl
chmod +x ~/bin/subdl

Create and install small script mplayer-sub.sh

cat > ~/bin/mplayer-sub.sh << EOF
#!/bin/bash

[[ -z "\$@" ]] && exit 0
interactive=""; if [[ "\$1" == "-i" ]]; then interactive="-i"; shift; fi

for file in "\$@"; do echo \$file; subdl \$interactive "\$file"; done
mplayer "\$@"
EOF
chmod +x ~/bin/subdl

Use

Well, shall we try? If you didn't have ~/bin directory before you should re-logon and if you did than let's go!
mplayer-sub.sh Once.Upon.a.Time.S02E12.HDTV.x264-LOL.mp4
or
mplayer-sub.sh ~/Video/Once.Upon.a.Time.S02E12.HDTV.x264-LOL.mp4
or even
mplayer-sub.sh ~/Video/Once.Upon.a.Time.*.mp4
In the last example it downloads English subtitles (English is default for subdl and can be changed) for all of the files those match Once.Upon.a.Time.*.mp4 and then mplayer plays them all.

It's simple, isn't it? :)

четверг, 6 декабря 2012 г.

Rails 3 + SQLite до версии Rails v3.2.2 и после

Столкнулся с проблемой при обновлении Redmine с версии 1.x на 2.x и решал её несколько дней. Оказывается разработчики Rails ИЗМЕНИЛИ ФОРМАТ ХРАНЕНИЯ БИНАРНЫХ ДАННЫХ при использовании SQLite и даже НЕ СООБЩИЛИ об этом в Changelog-е!

До версии 3.2.2 перед помещением данных в базу экранировались два символа, 0x00 и 0x25, их переводом в текстовое представление в, соответсвенно, и %25. А начиная с версии 3.2.2 эта часть кода была убрана и вы получаете НЕЦЕЛОСТНЫЕ ДАННЫЕ при попытке достать их с помощью Active Record.

Мне повезло, в моём случае эти данные были сжатыми и, соответственно, проверялись на целостность, так что данные просто не прочитались, но вот те, у кого целостность бинарных данных в базе не проверяется, поимеют большие проблемы при переезде с Rails до версии 3.2.2 (в том числе с любой версии 2.x) на более поздние.

Ссылки на это злополучное изменение:
- https://github.com/rails/rails/compare/v3.2.1...v3.2.2
- sqlite_adapter.rb commit
- pull request
Багрепорт в Redmine:
- http://www.redmine.org/issues/12501

суббота, 29 сентября 2012 г.

Смотрим последний выпуск ThisIsHorosho используя Tor

Один из выпусков ThisIsHorosho почему-то заблокирован для ряда стран, но это легко обойти. Один из способов - использовать Tor.

1. Скачиваем Tor Browser Bundle отсюда: https://torproject.org/download/download.
2. Распаковываем.
3. Открываем файл tor-browser/Data/Tor/torrc и добавляем cледующую строку:
ExitNodes {us}
4. Запускаем start-tor-browser, ждём, открываем http://www.geoiptool.com, чтобы проверить из какой страны идёт сединение (должно быть США)
5. Заходим в Tools -> Addons -> Extensions и отключаем NoScript (Youtube из-за него не работает). На вопрос о перезапуске браузера отвечаем согласием.
6. Окрываем ролик на Youtube.

PS: Если соединение слишком медленное нажмите "Use a New Identify" и откройте ссылку заново. Это переключит вас на другой ExitNode.