Author: Bian Xi

Unable to query DNS with DOMAIN from `dnsmasq` server

Unable to query DNS with DOMAIN from dnsmasq server

When doing nslookup, dnsmasq server could not reply the DNS with DOMAIN, but able to reply short dns name only. Following message may appear.

# nslookup www
....
dnsmasq server can't find www.example.com: NXDOMAIN

Solution

The reason is that DNS entries in dnsmasq host file (default is banner_add_hosts) has no domain name

192.168.1.1  www

In dnsmasq.conf file

Following lines are required. The expand-hosts option allows appending the domain name defined in domain line to short hostname in host file

domain=example.com,192.168.1.0/24
expand-hosts

References

Move MicroSD boot proxmox to eMMC

Move MicroSD boot proxmox to eMMC

Steps

  • Manually deplicate partition from MicroSD to eMMC using fdisk, ignore the bios partition as EFI partition used.
  • Unmount old /boot/efi partition, then duplicate EFI partition using dd from MicroSD, this can keep UUID
  • Create PV on eMMC data partition and add it to pve VG
  • Move all data from old MicroSD partition to eMMC partition
    pvmove /dev/<MicroSD partition>
  • Check structure and UUID using following command
    lsblk -o +UUID
  • Remove MicroSD PV from pve VG using vgreduce, then use pvremove to remove PV from MicroSD
  • Mount new /boot/efi partition, then run grub-install to recreate grub.cfg file
  • Remove MicroSD from system, then reboot

References

Changing IP address for all nodes in Proxmox Cluster

Changing IP address for all nodes in Proxmox Cluster

Steps

  • Change IP in all nodes in following files /etc/network/interfaces and /etc/hosts
  • Change all IP address in /etc/pve/corosync.conf
  • Reboot all nodes.

Troubleshooting

If above failed during the synchronization, use following commands to fix it.

  • Stop cluster services on the node that wasn't synchronized
systemctl stop corosync.service
systemctl stop pve-cluster
  • Update the corosync.conf file manually
vi /etc/corosync/corosync.conf
  • Restart cluster services
systemctl start corosync.service
systemctl start pve-cluster

Verify configuration file again and cluster status

cat /etc/corosync/corosync.conf
pvecm status

XRDP login with error related to color policies

XRDP login with error related to color policies

XRDP is the service service for Microsoft Remote Desktop Connection.

Note: XRDP desktop isn't the desktop of console, and it is also impacting the console login. So, don't use console and XRDP at same time.
Note: when I used VNC based software, the screen didn't refresh correctly.

Error

Following errors occurred, these error message can be bypassed by key in password or click on Cancel button and these are only appearing one the first connection established

Authentication is required to create a color profile
Authentication is required to create a color managed device

Reason

The authorization was not granted by Polkit on color management features to user remote login user. The errors are shown as below in file /var/log/auth.log, and the first line is for failed login.

Jan  2 08:07:56 baidu-ubuntu polkitd(authority=local): Operator of unix-session:c2 FAILED to authenticate to gain authorization for action org.freedesktop.color-manager.create-profile for system-bus-name::1.107 [/usr/libexec/gsd-color] (owned by unix-user:xxxxx)
Jan  2 08:08:36 baidu-ubuntu polkitd(authority=local): Operator of unix-session:c2 successfully authenticated as unix-user:xxxxx to gain ONE-SHOT authorization for action org.freedesktop.color-manager.create-profile for system-bus-name::1.107 [/usr/libexec/gsd-color] (owned by unix-user:xxxxx)
Jan  2 08:08:54 baidu-ubuntu polkitd(authority=local): Operator of unix-session:c2 successfully authenticated as unix-user:xxxxx to gain ONE-SHOT authorization for action org.freedesktop.color-manager.create-device for system-bus-name::1.107 [/usr/libexec/gsd-color] (owned by unix-user:xxxxx)

Fix

Create file called /etc/polkit-1/localauthority/50-local.d/45-allow-colord.pkla as below

/etc/polkit-1/localauthority/50-local.d/45-allow-colord.pkla

[Allow Colord all Users]
Identity=unix-user:*
Action=org.freedesktop.color-manager.create-device;org.freedesktop.color-manager.create-profile;org.freedesktop.color-manager.delete-device;org.freedesktop.color-manager.delete-profile;org.freedesktop.color-manager.modify-device;org.freedesktop.color-manager.modify-profile
ResultAny=no
ResultInactive=no
ResultActive=yes

References

How to Fix “Authentication is required to create a color profile/managed device”

Garmin Fenix – useful features

Garmin Fenix - useful features

Pause and Resume

Press start/stop button during activity is on.

  • To resume your activity, select Resume.
  • To save the activity and view the details, select Save, press Start button, and select an option.
  • To suspend your activity and resume it at a later time, select Resume Later.
  • To mark a lap, select Lap.
  • To navigate back to the starting point of your activity along the path you traveled, select Back to Start > TracBack.
  • To navigate back to the starting point of your activity by the most direct path, select Back to Start > Route.
  • To measure the difference between your heart rate at the end of the activity and your heart rate two minutes later, select Recovery HR, and wait while the timer counts down.
  • To discard the activity, select Discard.

Garmin Edge 1030 – useful features during cycling

Garmin Edge 1030 - useful features during cycling

Split long course

Garmin got bug when the Course is longer than 180 KM as my experiences, and it caused self reboot during recalculating. So I have to split the course into smaller segments, and this is also improve the loading time. Anyway, Garmin Edge isn't a fast computer.

Change Course during cycling

In order to load the next Course into Edge without stopping the activity, the following steps can be used

  • Touch the screen
  • Tap on Home icon
  • Tap on Navigation
  • Tap on Courses
  • Tap on the Course to load
  • Return to Home page
  • Tap on the round activity icon on top of screen to back to activity screen if needed

Pause/Resume activity

If the activity is on, the power button will lock the touch screen. Otherwise, will off the screen.

To Pause activity for lunch

  • Press start/stop button
  • Press power button to off the screen

Resume activity

  • Press power button
  • Press start/stop button

Merge activities

If the activity was stopped and saved, then the only way I know to merge with previous activity is using following online tool, but some useful information will be lost too, such as activity type, category, calories, etc.

https://gtt.feub.net/merge-activities/

Differences and Benefits Between i440fx and q35 in Proxmox

Differences and Benefits Between i440fx and q35 in Proxmox

My view

For application i440fx is enough, and it is simple, for hardware related, such as GPU passthru, then Q35 is better.

Switch between them

After switch between, the network interface name will be changed.

Q35

Q35 supports PCIe

  • Extended configuration space (MMCFG)
  • PCIe native hotplug
  • Advanced Error Reporting (AER)
  • Alternative Routing-ID Interpretation (ARI)
  • Native Power Management
  • Function Level Reset (FLR)
  • Address Translation Services (ATS)
  • AHCI storage controller
  • vIOMMU emulation
  • Secure Boot

Q35 limitations

  • No support for legacy guests (Windows XP/2000).
  • Questionable support for legacy QEMU devices.
  • Limited IO space can affect the number of devices used by a single Q35 machine

References

Differences/benefits between i440fx and q35 chipsets?
Q35 - QEMU
PCI vs PCI Express
PCI EXPRESS GUIDELINES

Escape Percent-signs(%) in crontab

Escape Percent-signs (%) in crontab

In order to input % character as command parameter in cron task, it needs to be escaped using backslash ().

man (5) crontab:

Percent-signs (%) in the command, unless escaped with backslash (\), 
will be changed into newline characters, and all data after the 
first % will be sent to the command as standard input.