BSD Chromium Audio/Mic

If you encounter a problem with microphone in Chromium on FreeBSD (and other *BSD), this is because it uses sndio audio backend and probably default microphone is not the one you want to use. In my case /dev/dsp0 is the HDMI input/output thus no audio input. There is no need to start system wide sndiod. You can use environment variables in ~/.profile to control audio input/output for the local spawning sndio client:

  • export AUDIODEVICE="rsnd/4" sets default input/output device to /dev/dsp4.
  • export AUDIORECDEVICE="rsnd/3" sets default input device to /dev/dsp3.
  • export AUDIOPLAYDEVICE="rsnd/2" sets default output device to /dev/dsp2.

You can simply set AUDIODEVICE="rsnd/4" to switch default input and output device, and/or AUDIORECDEVICE="rsnd/3" to change default microphone source. If you want to have choice to switch between several devices on the fly you will need to use sndiod and provide set of devices with -f flag. See sndio [1] and sndiod [2] man pages for more information.
[1] https://man.openbsd.org/sndio.
[2] https://man.openbsd.org/sndiod

fastboot too old problem

If you want to perform stock factory flashing of a Nexus device and you encounter “fastboot too old” error message, that means you need to update your local fastboot application to a newer version. One additional word would make this interesting error message self-explanatory..

FreeBSD on a Hybrid Graphics Laptop

If you happen to get a nice laptop with a powerful graphics card, such as polish HYPERBOOK SL502VR [1], it is highly probable that you will use UEFI boot mode. In that case you need to use SCFB [2] driver instead of VESA. Use the xf86-video-scfb package to get Xorg running.

Hybrid Graphics at first used MUX device that did a LCD connect to a selected video card on boot. Nowadays both cards use common Video Framebuffer [3] to draw over a screen. The simple video card (Intel in my case) is always active, while the more powerful and power consuming video card is started on-demand (nVidia in my case). This however requires a dedicated DMA BUF implementation, which is not yet available on FreeBSD, so none of the cards can see any monitor connected, resulting in “No Screens Found Error” from Xorg.

I have already reported a bug/feature request to nVidia. Also developers of FreeBSD are working on the Hybrid Graphics implementation.

[1] http://sklep.hyperbook.pl/hyperbook-sl502-vr-p651rp6g-gtx-1060-p-25965.html
[2] https://wiki.freebsd.org/Graphics/SCFB
[3] https://en.wikipedia.org/wiki/Framebuffer

OpenSC breaks GnuPG/SC on OSX

If you happen to work on OSX with MacPorts and GPGTools using SmartCard for SSH then installing OpenSC (0.16.0 in my case) will break your smart card access for GPG/SSH. If you remove OpenSC with an uninstall utility things get back to normal.

Google Android Nexus Device Un-Brick

GoogleNexus

If you happen to brick your Google Nexus device you can always use stock ROM images [1] to revert it to a default and operational state. Package contains not only OS but also bootloader and radio firmware images!

I have bricked my device by installing custom firmware that messed partitions layout inside a Flash Memory. I have seen lots of people having similar problem of endless bootloader-loop. There is no need to send a device to a service when bootloader is operational. All you need is a stock firmware image from Google [1], USB cable, and fastboot utility from Android SDK. If you happen to damage a bootloader, then hardware manipulation at low-level is necessary over JTAG, I can help to recover your device in that case.. no worries :-)

[1] https://developers.google.com/android/nexus/images

Fixing corrupted GPT backup

When you setup system on a fresh disk you may encounter a problem of corrupted GPT backup. This will happen even more likely when you messed with MBR before on that disk. Free and Open GDISK utility will help you. GDISK will tell you current state of the disk and partition tables, also warn you on possible problems. When you print available partitions (‘p’) and they seem okay, you can simply write out (‘w’) the partition table, that would fix the GPT backup corruption problem :-)

RAID HDD and UEFI BIOS

If you want to build your own disk array, let’s say RAID, on your computer to increase disk space and efficiency, you should know about few important things in general:

  • You can consider MBR and x86 obsolete. New way is GPT, UEFI, AMD64.
  • Large RAID arrays (over 2TB) will not work with older hardware and OS (except FreeBSD) due to architecture limitations.
  • To use large RAID volumes you must use GPT partition scheme. MBR will not do the job.
  • Some systems can use GPT only with UEFI BIOS (i.e. Windows works with GPT only via UEFI). You may be forced to buy new motherboard.
  • UEFI and GPT is totally different way of bootstrap so you can forget what you know about BIOS and MBR here.
  • Hard Drives have hidden corruption-fix mechanisms in firmware that will make your RAID array fail to operate. For RAID choose dedicated drives such as WD RED (not Green, not Black, not Blue).

In order to use GPT and UEFI I have replaced my nice ASUS M4A88TD-V EVO/USB3 motherboard with M5A97 R2.0 only because M4 series did not support UEFI. New BIOS is totally different, but I am not really sure if replacing the hardware was mandatory..

Summing up, if you want to use large RAID volumes make sure first that you can use GPT and UEFI BIOS is present on your AMD64 hardware. If not, still you can use the FreeBSD as it knows how to bypass some limitations. Also remember to use dedicated HDD for RAID operations.

OSX 10.10 Yosemite install/runtime problem

If you want to perform a fresh installation of OSX 10.10 Yosemite on an older MacBook(Pro) you can obtain the installer with AppStore and then create the USB installation media.

In case you encounter an Installer Verification Error that prevents you from installing the new system try the following. Its not the system date not bad download as internets says.

This may also help you when encountering problems (i.e. USB Mass Storage) after system upgrade to Yosemite.

Try these boot keyboard shortcuts until you hear boot sound two times:

  • Cmd+Alt+R+P when powering on the Mac (NVRAM Reset)
  • Alt+Ctrl+Shift+PowerON alltogether (SMC Reset)

No problem, you are wolcome :-)

Windows 7/Vista Installer

The new Microsoft Windows Vista/7 brought also new revolution to the installer and bootloader components. If you are in that group who gets their OS preinstalled on the computer and no backup DVD is attached, then you have really bad luck.

If MBR gets modified Windows won’t boot anymore, unless you use installer disk to fix the bootstrap. But hey – you may ask – where is my installer disk, I only got the preinstalled system with rescue partition on the hard drive! So if you dare to install BSD, Linux, or any OS other than Windows, beware and get the installer disk first. Also note that this is not Microsoft duty to provide that system disk, but the Manufacturer, so good luck with getting back what you paid for.

The other issue in Microsoft Windows Vista/7 installer is the nasty welcome screen that lets you select the language for further installation – but, in fact, there is no “Next” button and the list is “one click”, so if you click anything except your language on the list, there is no other choice but to use this foreign language for the installation process – because there is neither “Back” nor “Restart” button (like in the FreeBSD and Linux installers) on the following screen. You can only reboot the computer and wait few more minutes for the installer to load again… assuming that you have the disk and won’t click anything wrong on the welcome screen ;-)

Ah, by the way – you won’t get into fixing the previous installation if the active partition has changed and does not point to windows installation anymore. Also be prepared and download Ethernet Adapter drivers because fresh install does not contain any of them bundled, so in order to download all of the drivers you need at least network up and running. So called “backup disk” contains only system, no drivers.

Now tell me who really creates piracy?