Updated on: 2023-10-07
Connecting to X server over ssh a.k.a "Linux Remote Desktop"
- Install cygwin with X11 server
- Use putty to ssh to your Linux server. Make sure you enable X11 forwarding in putty
- In case you want to run X11 applications as another user, use sux instead of su.
Compiling swftools-0.9.1 on Debian 6.0 (AMD64) - 30.03.2011
- wget http://www.swftools.org/swftools-0.9.1.tar.gz
- tar -xvzf swftools-0.9.1.tar.gz
- cd swftools-0.9.1
- aptitude install zlib1g-dev libgif-dev libjpeg8-dev libfreetype6-dev libfftw3-dev libzzip-dev
- make
- make install
Some of the books I've read
- The Unicorn Project. A Novel about Developers, Digital Disruption, and Thriving in the Age of Data (Business, IT, Devops, Management) - Summer 2020
- The DevOps Handbook: How to Create World-Class Agility, Reliability, and Security in Technology Organizations (Business, IT, Devops, Management) - Fall 2018
- The Phoenix Project (Business, IT, Devops, Management) - Fall 2018
- The Pragmatic Programmer (IT, Programming) - Spring 2018
- Peopleware (Management, IT) - Spring 2018
- This Is Lean: Resolving the Efficiency Paradox (Business, Process, Management) - Spring 2017
- Läbimurre - äriprotsesside pideva täiustamise kunst (Business, Process) - Spring 2017
- Who Moved My Cheese? (Psychology, Business, Changes) - Fall 2016
- The Strangest Secret (Psychology) - Fall 2015
- Confessions Of An It Manager (Management, IT, Humor) - Summer 2009
Windows XP - ipconfig /registerdns not working
DHCP client service is responsible for registering the computer in the dns. If that service is not running usually a RPC error will occur.
Ocsng windows agent not detecting printers?
Well, too bad. Agent runs under LocalSystem user.
How to set e-mail headers almost correctly in python (no utf)
Here's a sample
You have bought a Western Digital MyBook Live edition, enabled SSH but somekind of mysterious ACL seems to be pulling the strings?
Check here: Trustees ACL
and check out /etc/trustees.conf
Thinking about integrating those pesky AHCI drivers to your Microsoft Windows XP ISO image?
Unfortunately this cannot be done in a reasonable manner. Reason is here but there are two workarounds:
Skype picking up an unused proxy from Firefox?
Skype crawls every profile in Mozilla directory and tries to use every defined proxy it can find. If You have ever enabled a proxy and then disabled it, but have not cleared proxy fields, Skype will try to use it. Sad as it is.
Microsoft Windows stuff
fix_w7.reg
fix_w7.cmd
fix_xp.reg
Ordinal 459 not found
Solution
cmd.exe crashing when running dir as a Microsoft Windows Active Directory domain user but not when running as a local admin on Microsoft Windows Server 2008
Your Regional settings are somehow damaged. Choose a different regional setting, click apply and then choose the correct regional setting. Found the solution from here.
Clean PDF from metadata
exiftool -all:all= input.file.pdf
qpdf --linearize input.file.pdf output.file.pdf
Microsoft Windows Network Location Awareness - 2015-09-13
The idea looks solid in the case of Network Location Awareness but that's about it. Making use of it boils down to programming in C++.
Have "fun":
Using curl for uploading to nextcloud - 2017-07-23
curl -u $USERNAME -T $SOURCEFILE "https://mehmehmeh/nextcloud/remote.php/webdav/$DESTINATIONFILENAME"
Can't login using ssh (disconnected ca 2 minutes after entering username and password) and logging in from ttyX hangs - 2017-08-15
Quickfix: restart syslog-ng
Longterm fix: fix Your syslog-ng config.
Listen to ERR - 2017-12-30
ERR icecast server
Wayback machine crawler TLS cipher suites - 2018-07-29
- Cipher Suites (29 suites)
- Cipher Suite: TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256 (0xc023)
- Cipher Suite: TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256 (0xc027)
- Cipher Suite: TLS_RSA_WITH_AES_128_CBC_SHA256 (0x003c)
- Cipher Suite: TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256 (0xc025)
- Cipher Suite: TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256 (0xc029)
- Cipher Suite: TLS_DHE_RSA_WITH_AES_128_CBC_SHA256 (0x0067)
- Cipher Suite: TLS_DHE_DSS_WITH_AES_128_CBC_SHA256 (0x0040)
- Cipher Suite: TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA (0xc009)
- Cipher Suite: TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA (0xc013)
- Cipher Suite: TLS_RSA_WITH_AES_128_CBC_SHA (0x002f)
- Cipher Suite: TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA (0xc004)
- Cipher Suite: TLS_ECDH_RSA_WITH_AES_128_CBC_SHA (0xc00e)
- Cipher Suite: TLS_DHE_RSA_WITH_AES_128_CBC_SHA (0x0033)
- Cipher Suite: TLS_DHE_DSS_WITH_AES_128_CBC_SHA (0x0032)
- Cipher Suite: TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 (0xc02b)
- Cipher Suite: TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (0xc02f)
- Cipher Suite: TLS_RSA_WITH_AES_128_GCM_SHA256 (0x009c)
- Cipher Suite: TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256 (0xc02d)
- Cipher Suite: TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256 (0xc031)
- Cipher Suite: TLS_DHE_RSA_WITH_AES_128_GCM_SHA256 (0x009e)
- Cipher Suite: TLS_DHE_DSS_WITH_AES_128_GCM_SHA256 (0x00a2)
- Cipher Suite: TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA (0xc008)
- Cipher Suite: TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA (0xc012)
- Cipher Suite: TLS_RSA_WITH_3DES_EDE_CBC_SHA (0x000a)
- Cipher Suite: TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA (0xc003)
- Cipher Suite: TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA (0xc00d)
- Cipher Suite: TLS_DHE_RSA_WITH_3DES_EDE_CBC_SHA (0x0016)
- Cipher Suite: TLS_DHE_DSS_WITH_3DES_EDE_CBC_SHA (0x0013)
- Cipher Suite: TLS_EMPTY_RENEGOTIATION_INFO_SCSV (0x00ff)
Useful stuff - 2018-09-09
SMTP DANE - 2018-09-11
Postfix, DANE and letsencrypt - 2018-09-11
TLSA record generator - 2018-09-11
DKIM and SPF - 2018-09-11
Make sure your postfix respects DANE - 2018-09-11
main.cf
- [...]
- smtp_dns_support_level=dnssec
- smtp_host_lookup=dns
- smtp_tls_security_level = dane
- smtp_tls_loglevel=1
- [...]
How certbot's renewal works? - 2018-09-27
Using Debian Stretch on armhf and wanting to use Gitlab-CE but cannot figure out the repositories? - 2018-09-28
Edit /etc/apt/sources.list.d/gitlab-ce.list and add the following lines:
deb https://packages.gitlab.com/gitlab/raspberry-pi2/raspbian/ stretch main
deb-src https://packages.gitlab.com/gitlab/raspberry-pi2/raspbian/ stretch main
Using GitLabCE with Apache in front - 2018-10-09
Apache must proxy requests to Gitlab. It's a bit tricky to get it right.Here's a nice reference how to get it working.
Want to run gitlab-runner on the Gitlab server? - 2018-10-10
Read this first.
Running an intranet wiki/website with links to outside resources? You are probably leaking via referer headers used by helpful browsers. - 2018-10-18
Remedy is here.
Want to version control /etc but salt/puppet/ansible/blah looks like overkill? - 2018-10-23
etckeeper to the rescue!
Should I use www or not in my domain? - 2018-11-11
You probably should use www.
Using Gnome Keyring and Seahorse looks empty? - 2018-12-22
"View" -> "Show Any". Reference
Fix up Ubuntu, install zoom and run it on startup. Useful for a permanent VTC computer - 2019-01-27
fix_ubuntu_sh
Installing Windows 10 unattended on an UEFI system - 2020-03-08
- Obtain the OS ISO you want to automate. For example use Firefox with extension "User Agent Switcher", specify Linux as your User Agent and download the iso from here. Please note that firefox with extension is needed because otherwise you cannot directly download ISO. Make sure that ISO will be mounted after reboot too.
- Install Windows 10 to a Virtual Machine and use that from now on
- Download and install Windows 10 ADK
- Make a "Windows 10 Vanilla" directory in c:\
- Copy all the contents from the ISO (which will show up as a DVD drive in Windows) to the "Windows 10 Vanilla directory"
- Fire up "Windows System Image Manager"
- Choose "Tools" -> "Create Distribution Share" and choose/create "c:\ADK Distribution Share" as target
- Choose "File" -> "Select Distribution Share" and chhose the distribution share made in the previous step
- Choose "File" -> "Select Windows Image" and choose "c:\Windows 10 Vanilla\sources\install.wim"
- Right Click on "Windows Image" -> Components -> amd64_Microsoft-Windows-International-Core-WinPE_*" and choose "Add Setting to Pass 1 WindowsPE"
- Choose "Answer File"-> Components -> 1 windowsPE -> amd64_Microsoft-Windows-International-Core-WinPE_neutral
- Fill in the settings on the right: InputLocale,SystemLocale,UILanguage,UserLocale. You can find the valid settings from here. For example: InputLocale: et-EE, SystemLocale: et-EE, UILanguage: en-GB, UserLocale: et-EE
- Set UILanguage to en-GB in "Answer File"-> Components -> 1 windowsPE -> amd64_Microsoft-Windows-International-Core-WinPE_neutral -> SetupUILanguage -> UILanguage
- Right click on "Windows Image" -> "amd64_Microsoft-Windows-Setup_*" -> "Disk Configuration" -> "Disk" and choose "Add setting to Pass 1 WindowsPE"
- Choose "Answer File" -> Untitled -> amd64_Microsoft-Windows_Setup_neutral -> "DiskConfiguration". Set WillShowUI to OnError.
- Select "Disk" beneath the DiskConfiguration. Set "Disk ID" to 0, "WillWipeDisk" to true
- Right click on "Create Partitions" and choose "Insert New CreatePartition". Do this 4 times in total.
- Modify the first "Create Partition": Extend: false, Order: 1, Size: 500, Type: Primary
- Modify the second "Create Partition": Extend: false, Order: 2, Size: 100, Type: EFI
- Modify the third "Create Partition": Extend: false, Order: 3, Size: 16, Type: MSR
- Modify the fourth "Create Partition": Extend: true, Order: 4, Type: Primary
- Right click on "Modify Partitions" and choose "Insert new ModifyPartition" four times
- Modify the first "ModifyPartition": Format: NTFS, Label: WinRE, Order: 1, PartitionID: 1, TypeID: DE94BBA4-06D1-4D40-A16A-BFD50179D6AC
- Modify the second "ModifyPartition": Format: FAT32, Label: System, Order: 2, PartitionID: 2
- Modify the third "ModifyPartition": Order: 3, PartitionID: 3
- Modify the fourth "ModifyPartition": Format: NTFS, Label: Windows, Letter: C, Order: 4, PartitionID: 4
- Right Click on "Windows Image" -> Components -> amd64_Microsoft-Windows_Setup_* -> ImageInstall -> OSImage -> InstallTo and choose "Add Setting to Pass 1 WindowsPE"
- Set DiskID: 0, PartitionID: 4 at "Answer File" -> Untitled -> amd64_Microsoft-Windows_Setup_neutral -> "ImageInstall" -> OSImage -> InstallTo.
- Right Click on "Windows Image" -> Components -> amd64_Microsoft-Windows_Setup_* -> UserData -> ProductKey and choose "Add Setting to Pass 1 WindowsPE"
- Set AcceptEula: true, Organisation: "Your Company name" at "Answer File" -> Untitled -> amd64_Microsoft-Windows_Setup_neutral -> UserData
- Set Key to the version you need at "Answer File" -> Untitled -> amd64_Microsoft-Windows_Setup_neutral -> UserData -> ProductKey. Check out the correct key from here.
- Right click on the "Windows Image" -> amd64_Microsoft-Windows-Shell-Setup_* and choose "Add setting to Pass 4 specialise"
- Set timezone at "answer files" -> Untitled -> 4 specialize -> amd64_Microsoft-Windows-Shell-Setup_neutral. List of timezones are available from here.
- Right click on "Windows Image" -> Components -> amd64_Microsoft-Windows-International-Core_*" and choose "Add Setting to Pass 7 oobeSystem"
- Fill in the settings on the right: InputLocale,SystemLocale,UILanguage,UserLocale. You can find the valid settings from here. For example: InputLocale: et-EE, SystemLocale: et-EE, UILanguage: en-GB, UserLocale: et-EE
- Right click on the "Windows Image" -> amd64_Microsoft-Windows-Shell-Setup_* -> OOBE and choose "Add setting to Pass 7 oobeSystem"
- Fill in the added options as necessary. Details about ProtectYourPC can be found from here. Choose 3 for the value
- Remove all unused settings be deleting the light purple boxes
- Click on Tools -> Validate. Fix any errors.
- Click File -> "Save Answer files as". Specify autounattend.xml as the filename
- Copy the file created to a usb stick. Have the usb plugged in when Windows setup boots. Setup will automatically look for autounattend.xml on the remove media and uses it when found
- Pat yourself on the back. Although this method is a good way to install Windows, it's a good way to install Windows only, without any specifc drivers or other software. For that, please check ou the next topic.
Installing Windows 10 unattended on an UEFI system and boot to audit mode to install other necessary stuff too - 2020-03-09
- Obtain the OS ISO you want to automate. For example use Firefox with extension "User Agent Switcher", specify Linux as your User Agent and download the iso from here. Please note that firefox with extension is needed because otherwise you cannot directly download ISO. Make sure that ISO will be mounted after reboot too.
- Install Windows 10 to a Virtual Machine and use that from now on
- Download and install Windows 10 ADK
- Make a "Windows 10 Vanilla" directory in c:\
- Copy all the contents from the ISO (which will show up as a DVD drive in Windows) to the "Windows 10 Vanilla directory"
- Fire up "Windows System Image Manager"
- Choose "Tools" -> "Create Distribution Share" and choose/create "c:\ADK Distribution Share" as target
- Choose "File" -> "Select Distribution Share" and chhose the distribution share made in the previous step
- Choose "File" -> "Select Windows Image" and choose "c:\Windows 10 Vanilla\sources\install.wim"
- Right Click on "Windows Image" -> Components -> amd64_Microsoft-Windows-International-Core-WinPE_*" and choose "Add Setting to Pass 1 WindowsPE"
- Choose "Answer File"-> Components -> 1 windowsPE -> amd64_Microsoft-Windows-International-Core-WinPE_neutral
- Fill in the settings on the right: InputLocale,SystemLocale,UILanguage,UserLocale. You can find the valid settings from here. For example: InputLocale: et-EE, SystemLocale: et-EE, UILanguage: en-GB, UserLocale: et-EE
- Set UILanguage to en-GB in "Answer File"-> Components -> 1 windowsPE -> amd64_Microsoft-Windows-International-Core-WinPE_neutral -> SetupUILanguage -> UILanguage
- Right click on "Windows Image" -> "amd64_Microsoft-Windows-Setup_*" -> "Disk Configuration" -> "Disk" and choose "Add setting to Pass 1 WindowsPE"
- Choose "Answer File" -> Untitled -> amd64_Microsoft-Windows_Setup_neutral -> "DiskConfiguration". Set WillShowUI to OnError.
- Select "Disk" beneath the DiskConfiguration. Set "Disk ID" to 0, "WillWipeDisk" to true
- Right click on "Create Partitions" and choose "Insert New CreatePartition". Do this 4 times in total.
- Modify the first "Create Partition": Extend: false, Order: 1, Size: 500, Type: Primary
- Modify the second "Create Partition": Extend: false, Order: 2, Size: 100, Type: EFI
- Modify the third "Create Partition": Extend: false, Order: 3, Size: 16, Type: MSR
- Modify the fourth "Create Partition": Extend: true, Order: 4, Type: Primary
- Right click on "Modify Partitions" and choose "Insert new ModifyPartition" four times
- Modify the first "ModifyPartition": Format: NTFS, Label: WinRE, Order: 1, PartitionID: 1, TypeID: DE94BBA4-06D1-4D40-A16A-BFD50179D6AC
- Modify the second "ModifyPartition": Format: FAT32, Label: System, Order: 2, PartitionID: 2
- Modify the third "ModifyPartition": Order: 3, PartitionID: 3
- Modify the fourth "ModifyPartition": Format: NTFS, Label: Windows, Letter: C, Order: 4, PartitionID: 4
- Right Click on "Windows Image" -> Components -> amd64_Microsoft-Windows_Setup_* -> ImageInstall -> OSImage -> InstallTo and choose "Add Setting to Pass 1 WindowsPE"
- Set DiskID: 0, PartitionID: 4 at "Answer File" -> Untitled -> amd64_Microsoft-Windows_Setup_neutral -> "ImageInstall" -> OSImage -> InstallTo.
- Right Click on "Windows Image" -> Components -> amd64_Microsoft-Windows_Setup_* -> UserData -> ProductKey and choose "Add Setting to Pass 1 WindowsPE"
- Set Key to the version you need at "Answer File" -> Untitled -> amd64_Microsoft-Windows_Setup_neutral -> UserData -> ProductKey. Check out the correct key from here.
- Right Click on "Windows Image" -> Components -> amd64_Microsoft-Windows-Deploymnet_* -> Reseal and choose "Add Setting to pass 5 auditSystem"
- Set Mode: Audit at "Answer File" -> Components -> 5 auditSystem -> amd64_Microsoft-Windows-Deployment_neutral -> Reseal
- Remove all unused settings be deleting the light purple boxes
- Click on Tools -> Validate. Fix any errors.
- Click File -> "Save Answer files as". Specify autounattend.xml as the filename
- Copy the file created to a usb stick. Have the usb plugged in when Windows setup boots. Setup will automatically look for autounattend.xml on the remove media and uses it when found
Updating OP to latest LineageOS - 2023-10-07
- apt install adb fastboot
- connect phone to computer
- adb reboot bootloader
- fastboot devices
- download images from here.
- download ARM64 gapps from here.
- fastboot flash recovery recovery.img
- reboot phone, check if you can boot to recovery
- reboot phone
- adb reboot sideload
- adb sideload /path/to/image and don't reboot. Apply update, apply from adb
- adb sideload /path/to/gapps
- Reboot system now