home Get a blog for free contact login

Home

Независимост

Ще ми се да кажа едно "Честита Независимост Българи!", ама ми е едно такова горчиво в устата.

Чета манифеста за независимост - доста страхливо написан. Обявен от Фердинанд, австриец, начело на "независима" България от 1887 та чак до 1918 г. За признаването от великите сили на независима България през 1909 г има тристранно споразумение Русия-Турция-България и българският дълг е прехвърлен от Турция към Русия.

Едно такова независимо ми е и днес, като гледам делата на пионките назначени да ръководят държавата. И медиите правят празника ни двоен - 111 години независимост, 111-то място ..

Независима България ? Не и в сегашния световен ред ..

И въпреки това .. Борбата срещу безчинствата и новите зависимости има нужда от хора дори още повече днес, отколкото преди 111 г. А дай Боже един ден децата ни да могат гордо да извикат

Честита Независмост Българи!


Debian releases - do not freeze, rather do a RC

Dear Debian,

OS ideology says - release early, release often.

Instead of doing "the freeze" I would go for RC releases. IMHO this would simplify the process a lot:

  • in sync with the release practice of most of the OSS out there
  • "testing" will not be blocked
  • no need to do complicated things, like blocking package migrations, submission of new packages, etc.
  • ...

Then, when you feel you're in a state for a new stable release just "name it".

A temporary intermediate version can be introduced:

  • experimental
  • unstable
  • testing
  • RC
  • stable
  • oldstable
  • ...

Posted in dir: /blog/
Tags: Debian OSS

toto.bg and timestamping

Toto.BG и TimeStamp-ing

Някакъв голям джакпот ми се мерна в тотото наскоро и пусках фиш последните два тиража. Не щеш ли обаче джакпота не падна и реших да видя дали може да се пуска фиш OnLine . Оказа се, че може. Може, обаче:

  • Плащането става със зареждане на "сметка" от кредитна карта или ePay.bg
  • Минималната сума за зареждане е 10 лв
  • Регистрираш се, зареждаш си сметката, пускаш си фиша и не получаваш нищо

Няма разписка за направения залог, няма електронен фиш - нищичко. Ако спечелиш - пак нищо. Една мижава нотификациика не получаваш.

Знаейки в каква мафиотска държава живеем лесно мога да си представя как си правиш залога, удряш печалбата и утре тия ти казват, че тоя фиш не е твой, или че никога не е съществувал.

Ако аз я правех тази система щях да изпращам документ подписан със сертификат на БСТ, с данните от фиша и регистрацията на играещия, с което да може да удостовери, че фишът е негов. От там нататък този документ щеше да е по-сигурен от хартиените фишове, на които преносителят се счита за собственик.

Реших лекичко поне да се застраховам, да си сваля фиша и да си TimeStamp-на файла. За целта написах набързо следния кратък скрипт:

#!/bin/bash -x

openssl ts -query -no_nonce -sha512 -data $1 -out $1.tsq

curl -H "Content-Type: application/timestamp-query" \
    --data-binary "@$1.tsq" https://freetsa.org/tsr > $1.freetsa.tsr

openssl ts -reply -text -in $1.freetsa.tsr

Ако решите да ползвате подобна "схема" е важно да имате подписания TimeStamp преди тегленето на тиража. Не е лоша идея и да се ползват подписи с няколко вида хеш суми и различни TimeStampingAuthority-та .

Позачетох се и в общите условия на сайта на тотализатора:

  • 50% от залозите се връщат като печалби
  • 30% отиват за българския спорт ( оставащите 20% явно са им за разходи )
  • Ако удариш джакпота може доста да почакаш докато ти го платят. Давали ти 200 000 лв бързичко, после по 30 000 лв на месец, като разсрочвали плащането за 14 години (ако има остатък ти го плащат чак накрая).

Тук ми изниква въпроса, при положение, че събират залозите предварително а разсрочват печалбите, какво се случва с тия пари междувременно ?

Проверих в търговския регистър и изглежда, че все още "Български спортен тотализатор" е държавна собственост

Уточнение: Не обичам хазарта. Тото играя по изключение и то защото играта е държавна и уж субсидира българския спорт. То не че мога да съм сигурен, че пак не въртят някакви схеми да ги крадат тия пари.

В допълнение: "Националната лотария" е собственост на Васил Божков - Черепа. Купуването на талоните му, освен демонстрация на нисък интелект е и директно спонсорство на мафията.

Полезни връзки:


Posted in dir: /articles/
Tags: FreeTSA timestamping Toto.BG

Passing boot parameters to ScaleWay's baremetal C1 instance Linux kernel

Passing boot parameters to ScaleWay's baremetal C1 instance Linux kernel

Short story

Add tags like these to your server:

KEXEC_KERNEL=http://mirror.scaleway.com/kernel/armv7l-mainline-lts-4.9-4.9.93-rev1/vmlinuz
KEXEC_INITRD=http://mirror.scaleway.com/initrd/uInitrd-Linux-armv7l-v3.14.6
KEXEC_APPEND=vmalloc=512M

Longer story

The ScaleWay's "BareMetal" "C1" instance is a cheap EUR 3 / month cloud infrastructure instance. It has:

  • 4 32bit armv7l cores
  • 2 GB RAM
  • 50 GB network attached storage
  • 1 public IP included in the price

ScaleWay offers two lines of servers:

  • BareMetal
  • VirtualMachines (KVM based)

One important difference between the two is that:

  • A VM can only be booted with as much storage as included in its offer
  • Bare metal instances support attaching up-to 15x150 GB additional network block device drives ( charged EUR 1/month per 50 GB )

Another important difference is that currently in ScaleWay infrastructure, contra-logically:

  • Only VMs can run custom kernels
  • Bare metal servers come with e pre-build kernels and ScaleWay does not officially support changing these kernels. You can't even run the official kernel that comes with the chosen Linux distro.

Thus a problem arises you need to change something.

My case was that I wanted to use ZFS and it is not included in the official Linux kernel. It is rather build as a module. On standard Debian it is done easily by installing the zfs-dkms package.

It is possible to build the module for the C1 instance kernel by preparing the build env like described here:

The problem was, that ZFS on 32bit Linux:

  • "May encounter stability problems"
  • "May bump up against the virtual memory limit"

which is officially stated here:

I'm stil about to see the former but hit the latter quite fast, and as recommended I had to add the vmalloc=512M boot parameter.

Unfortunately Scaleway does not support passing parameters to their kernels. They however support KEXEC via the KEXEC_KERNEL and KEXEC_INITRD params as documented here:

and they support parameters to the KEXEC-ed kernel via the KEXEC_APPEND param.

So as I just needed to boot the same kernel and pass the parameter. So first I had to find where the current kernel and initrd are. This is done by installing "scaleway-cli":

I've just grabbed the pre-built amd64 deb packages, and then used the "scw" command to get info about the instance:

# list servers
$ scw ps 

# Show instance details 
$ scw inspect SERVER_ID

"bootscript": {
    "bootcmdargs": "LINUX_COMMON scaleway boot=local nbd.max_part=16",
    "initrd": "initrd/uInitrd-Linux-armv7l-v3.14.6",
    "kernel": "kernel/armv7l-mainline-lts-4.9-4.9.93-rev1",
    "dtb": "dtb/c1-armv7l-mainline-lts-4.9-4.9.93-rev1",
    ...

If you inspect a VM instance you will see that the kernel and initrd are referred by IP:

"bootscript": {
    "bootcmdargs": "LINUX_COMMON scaleway boot=local nbd.max_part=16",
    "initrd": "http://169.254.42.24/initrd/initrd-Linux-x86_64-v3.14.6.gz",
    "kernel": "http://169.254.42.24/kernel/x86_64-mainline-lts-4.4-4.4.127-rev1/vmlinuz-4.4.127"

And a google search showed me that the kernel and the initrd were available at:

I've had a problem by trying to use the image referred in the params above:

# DO NOT USE THIS ONE
KEXEC_INITRD=http://mirror.scaleway.com/initrd/uInitrd-Linux-armv7l-v3.14.6

and I've wasted a couple of hours until I realized that this image was in a different format, not usable for the KEXEC_INITRD . Then I've changed it to:

 KEXEC_INITRD=http://mirror.scaleway.com/initrd/initrd-Linux-armv7l-v3.14.6.gz

and this time it worked fine.

The kernel can be found via at least two different URLs:

KEXEC_KERNEL=http://mirror.scaleway.com/kernel/armv7l-mainline-lts-4.9-4.9.93-rev1/vmlinuz
             http://mirror.scaleway.com/kernel/armv7l/4.9.93-mainline-rev1/vmlinuz

And after the successfull boot I've just had to add:

KEXEC_APPEND=vmalloc=512M

And my ZFS module was no longer complaining about lack of virtual memory.

Let me add a few articles that were helpful:

I've wasted about a day while investigating this stuff. If you find it helpful and you think that I might have saved you a couple of hours you can decide to send me a small donation on this PayPal e-mail: krustev-paypal@krustev.net


Posted in dir: /articles/
Tags: BareMetal Debian Linux ScaleWay ZFS

GigaByte T1028M with Debian Buster

GigaByte T1028M with Debian Buster

I bought this small netbook about 10 years ago(2008) and my grandma was using it for Skype in the last 5+ years. I got her a tablet recently as the netbook was getting unsupported and quite slow (WinXP, 32 bit only).

When I bought it I've installed Debian on it and kept the WinXP available on a small resized partition. It was a pain back then to get some of the hardware working, e.g. the touch screen and the Elantech touchpad.

When I got it back I decided to update it to an up-to date Debian and since Buster was coming in a few months it was the candidate. I expected everything to be working out-of-the box but unfortunately it wasn't. So I've decided to put down this little article as a reminder.

Elantech touchpad not working

The multitouch mouse was not working after default Debian Buster install so:

# Add the following kernel parameter to /etc/default/grub
i8042.noloop=1

Suspends on each 10 seconds before logging-in

# Make sure you have this in /etc/systemd/logind.conf
HandleLidSwitch=ignore

Hardware

  • The processor is very slow - Intel Atom N270, 1.6 GHz, Single core with HyperThreading
  • HDD is very very slow. I will probably change it with a small SSD laying around.
  • Only 1GiB DDR2 RAM . Upgradeable to 2GiB (one DIMM socket only supporting 2GiB)
  • I think the mouse is generating interrupts, so "paste" does not work in the GUI (currently Cinnamon)
  • The touch screen worked with no additional configuration
  • It has BlueTooth, SD CardReader, Internal 3g modem with a SIM card slot, Camera

Keyboard

Bulgarian phonetic keyboard layout does not work with the default keyboard type for a US locale. I had to choose Acer laptop .

BIOS

BIOS update to latest version - May 10th 2010, ver.FD , is supposed to fix some problems, e.g.:

  • Add SSD flash drives support
  • WiFi card On by default (confirmed)

To upgrade the BIOS I've used Grub chainload to FreeDOS .

Desktop environment and software

Desktop environment

I've tried all offered desktop environments to choose what works best.

  • Gnome is very slow and eats too much memory
  • KDE/Plasma is my favorite on the desktop. It mostly works but is sluggish from time to time on this tiny CPU.
  • I've not experimented too much with Cinammon/LXDE

I've stuck with MATE as it works relatively fast and is lightweight. I was also able to set it up to my preferences with very little configuration .

Boot manager

  • I've chosen lightdm as it seems fast and lighweight
  • gdm is sluggish
  • sddm not that much but still slower than lightdm

Web browsers

At the time of install chromium was not available in Buster. So I've set up a mixed Buster/Sid system in order to be able to use it from Sid. It seems that ffmpeg dependencies were blocking its Buster presence.

  • Firefox works but
  • Chromium looks faster. Heavy sites like Facebook are slow. Youtube plays videos in its 360p resolution fine. 480p also works.

Якото лято

24-ти август 2018, известен още като денят, в който за пръв път си пускам вентилатор това лято. Понапекло беше следобяда и ми стана топло по едно време.

Досега това лято климатик съм пускал само в колата няколко пъти, като беше напечена.


Posted in dir: /blog/

Терминал 2

Терминал 2 не е решение бе тикви кухи. Същата тая прогнила смрад се носи на там, на където летите. Единственото, което ще направите е да се залъжете, че бездействието ви там няма да бъде забелязано. Ще пропилеете един живот, единственият ви живот, да се залъгвате, че благата, до които се докосвате ви носят удовлетворение.

Същевременно ще гледате как целият свят прогнива. В американската ви мечта заради същите тия продажни политици и банкери фалират градове, хората умират от същите тия отрови в храните, водата и въздуха. Океаните биват унищожавани, горите изкоренявани, животните избивани. За вас - отрова в лъскаво пликче, на вид и вкус като храна ..

Остров на спасението няма. Колкото и да ви се иска! Всичко и всички на тая планета са свързани. Спасението по единично не е вариант.

А благата на запад - ползвайте си ги. За да не бъдете лицемерни обаче, преди това погледнете наследниците си в очите и ги заплюйте!

И след това във весел унес продължете да се носите по течението ..

--

Делян


Posted in dir: /blog/

Мъдрец!

На 38 години, днес, 28 март 2018г, най-накрая се показа първият ми мъдрец.

Преди 5-6 години имах преживяване с предоверяване на зъболекърка. Имах леко възпаление на венеца, и жената ме прати на снимка. Виждаше се, че растат към другите зъби. Теорията ѝ беше, че мъдреците ги натискат и ги разместват, което отваря дупки м/у венците и зъбите. Предложи да извадим мъдреца. Макар, че нямах проблеми с болка и криви зъби и се доверих. Каза, че идвам, вадят го за 15 минути и си отивам на работа. Две седмици бях в болничен заради интервенцията. Хирурга беше голям неграмотник. Макар, че се виждаше на снимката, че мъдреците са дълбоко тръгна да го вади и се оказа, че няма необходимото "борче" за да разреже зъба на две за да може да го извади. 4 упойки ми би, щеше да бие и 5-та. Челюста ми едва остана здрава при едно от напъванията му. Въпросната зъболекарка (Биляна, работи в Люлин 9, ул "Тодор Влайков" 25), която асистираше, излиза няколко пъти защото ѝ ставаше лошо от гледката в устата ми. След повече от два часа на масата и купчина с кървави тампони уж успя да го извади и пристъпи към зашиване. Съответно се оказа, че вътре е останало огромно парче, което ми правеше проблеми докато не го извади д-р Чуканов (повече от 6 месеца по-късно). Лявата половина на долната ми челюст от тогава насам няма нормална чувствителност - като изтръпнала е. На моменти се забелязва, и че кривя устата на една страна докато говоря или се усмихвам.

Та при снимката направена при гореописания преглед се виждаше, че мъдреците ми няма шанс да се покажат някога. Имам навика отвреме навреме докато си ровичкам из устата да си броя зъбите. С удивление днес преброих 8 зъба горе в ляво вместо обичайните 7. Въобще не бях усетил наличието на "чуждото тяло".


Posted in dir: /blog/

Здравни осигуровки

Информативно, вноската за здравни осигуровки за самоосигуряващите се:

2016 - 16,80 лв
от 1.1.2017 - 18,40 лв
от 1.1.2018 - 20,40 лв

Posted in dir: /blog/

InfoNotary SmartCard config in Firefox and Chrome on Debian Stretch

InfoNotary maintain a useful wiki on the subject here:

http://wiki.infonotary.com

Configure the reader and the smart card

My reader is:

# lsusb
Bus 006 Device 002: ID 076b:6622 OmniKey AG CardMan 6121

The installation instructions are here:

http://wiki.infonotary.com/index.php/Инсталация_на_драйвери_за_четец_и_смарт_карта_в_Linux

Not all steps described there are needed. Here are mine:

  • Install pcscd and opensc packages
  • Check that openct is not installed (Not found in Debian Stretch when I'm writing this.)

pcscd depends on libccid which should NOT be installed. I've installed the pcsc-omnikey package which has the necessary Provides and purged libccid. pcsc-omnikey is available in the InfoNotary Debian package repository:

http://wiki.infonotary.com/index.php/Използване_на_хранилищата_на_InfoNotary

# wget -qO - http://repository.infonotary.com/install/linux/INotaryCodeSigning.key.asc | sudo apt-key add -
# wget http://repository.infonotary.com/install/linux/infonotary.list -qO /etc/apt/sources.list.d/infonotary.list
# apt-get update

I use aptitude and do the libccid purging and pcsc-omnikey install in one step. Then:

# systemctl stop pcscd.service
# pcscd --foreground

Check the pcscd output for the reader and use Ctrl+C to stop it.

I do NOT install the official OmniKey driver ifdokccid_linux .

Edit the file /etc/opensc/opensc.conf find the following section and set these values:

reader_driver pcsc {
     max_send_size = 0;
     max_recv_size = 0;

Then you can:

# systemctl start pcscd.service

Configure Firefox

The instructions are here:

http://wiki.infonotary.com/index.php/Използване_на_квалифициран_електронен_подпис_в_Mozilla_Firefox_за_Linux

On this page they recommend installation by using a FireFox extension. I do it manually though and it is shown with screens here:

http://wiki.infonotary.com/index.php/Използване_на_квалифициран_електронен_подпис_в_Mozilla_Firefox_за_Windows

Download the InfoNotary certs from here (from the menu - "публичен регистър->удостоверения на ИнфоНотари"):

http://www.infonotary.com/site/?p=doc_g1_3

You can import the individual "cer" files in the Authories section or the entire chain "p12" file. Do not forget to check the trust of individual imported certs.

Then on the same page:

http://wiki.infonotary.com/index.php/Използване_на_квалифициран_електронен_подпис_в_Mozilla_Firefox_за_Windows

it is shown how to activate the reader in Firefox. The path to the lib in Debian Stretch x86_64 is:

/usr/lib/x86_64-linux-gnu/onepin-opensc-pkcs11.so

The signing functionality has been removed from Firefox 35+, so in order to do signing from the browser you need a Firefox extension. There are two which are known to work and you can try them one by one "SignTextJS" and "SignTextJS plus"

Configure Google Chrome

It is well described here:

http://wiki.infonotary.com/index.php/Използване_на_квалифициран_електронен_подпис_в_Google_Chrome/Chromium_за_Linux

Further

I use the SmartCard for access to:

  • epay
  • FiBank
  • НАП

For НАП access these certs should also be imported into Chrome/Firefox:

https://inetdec.nra.bg/eservices.html


Posted in dir: /articles/

Page 17 of 29 (290 articles found)
start ... < ... 12 13 14 15 16 17 18 19 20 21 22 ...> ...end

All tags SiteMap Owner Cookies policy [Atom Feed]