A note about a ftp service

9 11 2017

From the reasons in Debian about shutting down public FTP services:

  • FTP servers have no support for caching or acceleration.
  • Most software implementations have stagnated and are awkward to use and configure.
  • Usage of the FTP servers is pretty low.
  • The protocol is inefficient and requires adding awkward kludges to firewalls and load-balancing daemons.

More info: https://www.debian.org/News/2017/20170425


Add multiarch Debian 9

18 08 2017

dpkg --add-architecture i386
apt-get update
apt-get install libc6:i386

Debian Stretch 9 issue with vim: copy and paste

20 06 2017

In Debian Stetch 9 there is a new behaviour in vim, the copy and paste with the mouse is unusual and don’t work as the previous versions did. For fix it:

Edit the file (or create it): /etc/vim/vimrc.local with the following content:
runtime! defaults.vim
let g:skip_defaults_vim = 1
set mouse=

More info: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=837761#76

Old solution:

In the file /usr/share/vim/vim80/defaults.vim comment the lines:

" if has('mouse')
" set mouse=a
" endif

Enable autologin in Debian with Systemd

19 05 2017

For allow autologin in a Debian system with systemd (very usefull with testing virtual machines):

Create dir:
mkdir /etc/systemd/system/getty@tty1.service.d/

Create file /etc/systemd/system/getty@tty1.service.d/override.conf with the following content:
ExecStart=-/sbin/agetty --autologin root --noclear %I $TERM

More info:

Boot Debian system with EFI Stub kernel

31 08 2016

I try to explain the process of install a Debian system with UEFI and use the EFI Stub property for load the kernel and the ram disk directly from the EFI system firmware, leaving aside “grub-efi” and scratching some seconds at boot time.

– Be sure that UEFI is enabled in your system booting firmware.

– Install Debian following the normal way until the partitioning step.

– UEFI require the following partitioning points:

* Around "500MB" of space
* Bootable flag on
* Partition type "EFI System Partition"

You can select automatic partitioning, and the Debian Installation process will create it automatically or doing the partitioning by hand using the indicated values.

Don’t create this partition under software RAID or LVM, the UEFI won’t read the files under that.

– End with the installation and reboot. If it went correctly, you have a polish running system, booted with grub-uefi, with the UEFI partition mounted under /boot/efi:

/dev/sda1 on /boot/efi type vfat (rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=utf8,shortname=mixed,errors=remount-ro)

– Now is time to change the boot process into a EFI Stub, copy the kernel and the ram disk into the UEFI partition:

# cp /vmlinuz /initrd.img /boot/efi/EFI/debian/

– Look for your root filesystem UUID (in this example is sda2, the place were the linux is installed):

# blkid /dev/sda2
/dev/sda2: UUID="955548bd-9c77-4893-8633-3a5e7966dfc9" TYPE="ext4" PARTUUID="4cd59271-18a2-4d00-a65a-a106ee030a1a"

– And create an entry into the UEFI firmware for the linux EFIStub (replace the UUID number with your particular reference):

# efibootmgr -c -g -L "Debian (EFI stub)" -l '\EFI\debian\vmlinuz' -u "root=UUID=955548bd-9c77-4893-8633-3a5e7966dfc9 ro quiet rootfstype=ext4 add_efi_memmap initrd=\\EFI\\debian\\initrd.img"

– Check the UEFI information, the new entry is at the bottom:

# efibootmgr -v
BootCurrent: 0004
BootOrder: 0005,0004,0000,0001,0002,0003
Boot0000* EFI Virtual disk (0.0)
Boot0001* EFI VMware Virtual IDE CDROM Drive (IDE 1:0)
Boot0002* EFI Network
Boot0003* EFI Internal Shell (Unsupported option)
Boot0004* debian
Boot0005* Debian (EFI stub)
root@uefi:/boot/efi/EFI/debian# efibootmgr -v
BootCurrent: 0004
BootOrder: 0005,0004,0000,0001,0002,0003
Boot0000* EFI Virtual disk (0.0) ACPI(a0341d0,0)PCI(15,0)PCI(0,0)SCSI(0,0)
Boot0001* EFI VMware Virtual IDE CDROM Drive (IDE 1:0) ACPI(a0341d0,0)PCI(7,1)ATAPI(1,0,0)
Boot0002* EFI Network ACPI(a0341d0,0)PCI(16,0)PCI(0,0)MAC(MAC(005056948a0a,1)
Boot0003* EFI Internal Shell (Unsupported option) MM(b,e1a3000,e42ffff)FvFile(c57ad6b7-0515-40a8-9d21-551652854e37)
Boot0004* debian HD(1,800,ee000,4f3b579c-10cb-44ca-b845-475b2409eaf7)File(\EFI\debian\grubx64.efi)
Boot0005* Debian (EFI stub) HD(1,800,ee000,4f3b579c-10cb-44ca-b845-475b2409eaf7)File(\EFI\debian\vmlinuz)r.o.o.t.=.U.U.I.D.=. .r.o. .q.u.i.e.t. .r.o.o.t.f.s.t.y.p.e.=.e.x.t.4. .a.d.d._.e.f.i._.m.e.m.m.a.p. .i.n.i.t.r.d.=.\.E.F.I.\.d.e.b.i.a.n.\.i.n.i.t.r.d...i.m.g.
Boot0007* Debian HD(1,800,ee000,4f3b579c-10cb-44ca-b845-475b2409eaf7)File(\EFI\debian\grubx64.efi

– Look close to the information reported, the BootOrder have the new entry listed first, in the next boot the system will take it:

BootCurrent: 0004
BootOrder: 0005,0004,0000,0001,0002,0003

– Now, reboot and check the BootCurrent again:

BootCurrent: 0005
BootOrder: 0005,0004,0000,0001,0002,0003

– Basically it’s done. But for update the kernel and the ram disk automatically when an upgraded is installed, or removed, create the following files and make them executable:

# cat > /etc/kernel/postinst.d/zz-update-efistub << EOF
echo "Updating EFI boot files..."
cp /vmlinuz /initrd.img /boot/efi/EFI/debian/

# chmod +x /etc/kernel/postinst.d/zz-update-efistub# cp /etc/kernel/postinst.d/zz-update-efistub /etc/kernel/postrm.d/zz-update-efistub

As a note, is it possible to substitute this script with systemd units. Look into the Arch linux wiki for more info.

– Thats all.



— But if you have some problems:

– If you need to revert the chage, for example, to keep boot0004 first again, execute:

# efibootmgr -o 0004,0005,0000,0001,0002,0003

– If you lost the Debian entry created at installation time, recrete it with this:

# efibootmgr -c -g -L "Debian" -l '\EFI\debian\grubx64.efi'

– If you have problems with EFI variables, be sure that you have installed “efivar” and “efivars” kernel module loaded (modproble efivars).


More info:

Fix dns problem with OpenVPN in Debian 8 Jessie

29 04 2015

If the openvpn connection don’t assign automatically the DNS setting from the servers, you need to put the script in the correct place.

After installing openvpn:
cp /etc/openvpn/update-resolv-conf /usr/share/openvpn/
chmod ugo+x /usr/share/openvpn/update-resolv-conf

That’s all. Connect again and review your resolv.conf

Install official vmware-view-client in Debian 8 Jessie

28 04 2015

As 2017, this document is deprecated, please, follow the method indicated here: https://elhombrequereventodeinformacion.wordpress.com/2017/02/24/1969/


For x64 systems aren’t available the official pacakge of Vmware View Client. The only solution is make the trick with an old Ubuntu version package and the multiarch support of Debian.

First, add the x86 multiarch support:
dpkg --add-architecture i386
apt-get update

Install Gdebi for an easy dependency resolution:
apt-get install gdebi
Download libssl and vmware-view-client from Ubuntu site or from my github account:
wget 'http://archive.canonical.com/ubuntu/pool/partner/v/vmware-view-client/vmware-view-client_2.2.0-0ubuntu0.12.04_i386.deb'
wget 'http://mirrors.kernel.org/ubuntu/pool/universe/o/openssl098/libssl0.9.8_0.9.8o-7ubuntu3.2_i386.deb'
wget 'https://github.com/rfrail3/misc/blob/master/vmware/vmware-view-client_2.2.0-0ubuntu0.12.04_i386.deb?raw=true'
wget 'https://github.com/rfrail3/misc/blob/master/vmware/libssl0.9.8_0.9.8o-7ubuntu3.1_i386.deb?raw=true'

Install the packages and accept dependencies:
gdebi libssl0.9.8_0.9.8o-7ubuntu3.1_i386.deb
gdebi vmware-view-client_2.2.0-0ubuntu0.12.04_i386.deb

If all was ok, the new VMware View Client is available under your desktop menu.