Archive for the ‘Quick Tips’ Category

Linux Mint 18.1/Ubuntu 16.04 on the Dell Precision 5510

02 Dec

as of December of 2016

My New Dell Precision 5510 laptop came with Linux, cool, but it was Ubuntu 14.04, not so cool.  So I’ve been fighting with a clean install of Linux Mint 18.1 (based on Ubuntu 16.04) on the laptop to get it to work perfectly with the laptop. My friend (who got the same laptop and did the same thing) and I kept finding strange little quirks/issues/annoyances and we ended up implementing 6 or 7 various fixes/workarounds/enhancements to cover all the little issues. We’re still not out of the woods 100% yet but everything is working for the most part.   I got annoyed and wondered what Dell had done to the Ubuntu 14.04 to address these issues, so I backed up everything and reverted to Dell factory image. And… it turns out Dell only solved 1 or 2 of the issues/quirks. So they really didn’t adjust Ubuntu 14.04 to their laptop very well as far as I can tell. Very disappointing, but I guess it’s “nice” that the laptop came with factory Linux in general.

Most of my issues centered around the touchpad, I kept accidentally mis-clicking everytime I was typing it, my left hand’s thumb would graze the upper left hand corner of the touchpad and make mis-clicks. The setting  “disable touchpad inwhile typing” in Preferences/Mouse and Touchpad  doesn’t work! This appears to be a very common issue, especially with Dell laptops/touchpads.

1. The first thing discovered was that Linux detected 2 touchpads, one called “SynPS/2 Synaptics TouchPad” and one called “DLL06E5:01 06CB:7A13 Touchpad”, one was generic the other was Dell specific. So I had to modify  /usr/share/X11/xorg.conf.d/51-synaptics-quirks.conf and put an ignore rule for “SynPS/2 Synaptics TouchPad”. This made only the DLL06E5 one be detected, which helped out with some issues. The touchpad felt better/more responsive afterwards.

Run: “xinput list” and verify you see a DLL…  and a “SynPS/2 Synaptics” input.
Fix: Modify /usr/share/X11/xorg.conf.d/51-synaptics-quirks.conf and add this to the bottom:

Section “InputClass”
Identifier “SynPS/2 Synaptics TouchPad”
MatchProduct “SynPS/2 Synaptics TouchPad”
MatchIsTouchpad “on”
MatchOS “Linux”
MatchDevicePath “/dev/input/event*”
Option “Ignore” “on”

2. However that still didn’t fix the “disable touchpad while typing” issue. I initially found that running “/usr/bin/syndaemon -i 1 -K -d” would work, it’d disable the touchpad for up to 1 second after the last keyboard button was pressed. It actually conflicts with the GUI settings application though, you have to uncheck “disable touchpad while typing” before running that syndaemon command, otherwise the settings “fight” and the touchpad gets completely disabled. However, that solution was crude at best and I still found I just didn’t enjoy the touchpad, it was much more usable now but it could be better, and I also wanted mouse gestures support, so I could 3 finger swipe to another workspace and maybe some pinch-to-zoom action, etc. So I ended up installing “xserver-xorg-input-libinput” which changed from the synaptics driver to the libinput driver. Much better.  You have to remember to disable the catch-all synaptics rule in 50-synaptics.conf. Once I was on libinput instead of synaptics though, that setting “disable touchpad while using keyboard” worked perfectly, so you don’t have to do that syndaemon thing anymore. Smooth.

Fix: “aptitude install xserver-xorg-input-libinput libinput-tools”  and then modify /usr/share/X11/xorg.conf.d/50-synaptics.conf and comment out this Section at the top:


#Section “InputClass”
# Identifier “touchpad catchall”
# Driver “synaptics”
# MatchIsTouchpad “on”
## This option is recommend on all Linux systems using evdev, but cannot be
## enabled by default. See the following link for details:
# MatchDevicePath “/dev/input/event*”


Then reboot.

3. I discovered issues with the touchscreen though, I then learned libinput was also trying to control the touchscreen. It turns out “evdev”, the driver that was previously handling the touchscreen, was better at it. So I ended up modifying 90-libinput.conf to disable handling of the touchscreen. So now I had a solid touchpad (libinput) and touchscreen (evdev). I still wanted gestures support though, but there was no package for libinput-gestures (arch linux has one), I ended up having to grab the source from git and compiling and installing it. And now I could suddenly 3-finger swipe between workspaces.

FIX 1: Modify /usr/share/X11/xorg.conf.d/90-libinput.conf and commenting out the touchscreen section at the bottom

#Section “InputClass”
#Identifier “libinput touchscreen catchall”
#MatchIsTouchscreen “on”
#MatchDevicePath “/dev/input/event*”
#Driver “libinput”


(Hint, xinput list-props ##  should help you determine what driver is being used, my touchscreen (shown in xinput list) was id=12  so I just ran xinput list-props 12 and I saw a bunch of properties beginning with libinput, letting me know which driver was being used)

FIX 2: Install libinput-gestures

sudo apt-get install xdotool wmctrl
cd libinput-gestures-master
sudo gpasswd -a $USER input
sudo ./libinput-gestures-setup install

4. The fun’s not over though. I discovered that when I connected an external monitor, the touchscreen would be off alignment. You have to re-associate the touchscreen input to just the laptop’s monitor by running either “xsetwacom set “ELAN Touchscreen” MapToOutput eDP1″ or more eloquently “xinput –map-to-output 14 eDP1” or something like that. I had issues with the xsetwacom command, using xinput seemed cleaner. Running that command realigns the touchscreen to the LCD display, but… when you disconnect the external monitor it again becomes out of alignment. Running that command yet again fixes it. So it seems you have to run that command everytime you connect or disconnect the external monitor. I ended up creating a /etc/udev/rules.d/99-monitor-hotplug.rules file that would run that command everytime there was a card0 drm change action (aka connecting and disconnecting an external monitor). This works but it’s not perfect, it messes up once in a while and I have to run the command manually (I’ve mapped it to F7 so I can just tap F7 and it fixes the touchscreen), I’ve also discovered that when connecting the monitor it actually triggers 3 change events so the command gets executed 3 times. It’s odd. I’m still investigating these 2 issues (sometimes the command doesn’t work when run by udev and why it’s being executed 3 times on connect).

5. I was on the nvidia card, with the very latest nvidia drivers, but decided to try out the Intel graphics. I switched to intel. Not bad, it wasn’t choppy even when running the internal and the external 4k monitors. But then randomly when I connected or disconnected the external monitor, the whole thing would randomly ‘lock up’. I could see the mouse cursor and move it, but I couldn’t do anything else. Even ctrl+alt+backspace and/or ctrl+alt+f1 wouldn’t work. There was no way out of xorg, I was stuck. I had to hard power cycle the laptop. This happened multiple times and initially I thought it was all my playing around in udev but after undoing my changes one by one and still encountering the issue, I eventually remembered I was on the Intel graphics, when I switched back to nvidia, no more lock ups. I used the “Intel Graphics Update tool” from Intel to try and upgrade the Intel drivers to the latest, but then switching back to intel and rebooting and then testing a monitor connect or disconnect the problem reoccurred, worst yet it was no longer “randomly” happening, it seemed to happen every single time; ouch.  So those upgraded Intel graphics drivers made things worst. Switching back to nvidia the issue went away.
Update:  this, and subsquently this: may solve the issue. From that github link I’ve downloaded their 20-intel.conf file and since I’m on the 4.4.x kernel I’ve also grabbed the 4.3 sklguc firmware and installed it. Theoretically the freezing problem may be resolved but I haven’t yet had the chance to test it.

6. I discovered the wifi only connects at 400mbps. This laptop has 802.11ac and should be capable of doing 1gbps, but it would only connect to the 802.11ac 5ghz AP at 400mbps. This has something to do with the iwlwifi driver, but I’ve tried various things and can’t seem to get it to connect any faster. I still haven’t “solved” this issue or tried other access points.
Update: It seems to be dependent on the Access Point. Using the uniquity wireless 802.11ac AP’s using Linux Mint 18.1 (Ubuntu 16.04 based) it only linked at 400mbps and speedtests confirmed it.  But going back down to Ubuntu 14.04 you could see it only link at 85mbps, and speedtests confirmed it (ouch!).  But… I’m now on an Asus 802.11ac Wireless Router and I’m linked at 866.7mbps. So the best I can tell is, it’s sensitive to the access point it’s talking to. Maybe something to do with the chipset.  I know the Ubiquity 802.11ac AP’s are capable of much more than 400mbps, but whatever. This issue has been downgraded, in my mind, to ‘minor annoyance’.

7. And lastly, I discovered kernel errors (see below). I initially thought it was the wifi but eventually traced it to nvidia when there’s an external monitor connected. Whenever I have an external monitor connected I’d get strange kernel messages indicating some kind of crash but it’s a very weird message and technically everything was working, even HDMI audio. I eventually discovered others having the issue with the latest Intel Skylake and such. There was a patch put into the 4.8.x kernels, which is crazy new, my laptop was running 4.4.x. There was no “easy” way to get to 4.8.x, I grabbed the deb files from Ubuntu (there was no ppa and nothing in any repository) and installed it but it had issues with some of the dkms stuff with nvidia and virtualbox. Apparently nvidia and virtualbox has some ‘kernel modifications’ that gets done and dkms helps those modifications persist across kernel changes. But these modifications did not like the bleeding edge 4.8.x kernel. I solved the nvidia problem, can’t remember how, but the virtualbox issue I couldn’t solve. However when running on the 4.8.x kernel the errors in the kernel logs when having an external monitor connected did go away.

So this is made me go “what the heck did Dell do to Ubuntu 14.04 to address all these issues” so I backed up everything important and reinstalled the factory Dell OS only to discover the majority of the issues still existed there, including the kernel errors. The touchpad stuff is still broken in Dell’s image. They did solve the touchscreen alignment issue though. I need to look into how they did that. But in general, Dell’s 14.04 image doesn’t have half the fixes, still seeing kernel errors (traced it to the nvidia drivers), and still not able to disable the touchscreen. Actually what was really “funny” was the wifi was now connecting to the Ubiquiti AP’s at 86.7mbps instead of 400mbps. It was horrific.   So I ran back to Mint 18.1 and re-implemented all those changes I mentioned above. The laptop is quite usable.

For now I’ve decided not to run the 4.8.x kernel, the dkms complications it introduces is not worth the hassle and while there are scary looking errors in the kernel log it doesn’t seemingly affect anything. Dell decided not to address it in their official Ubuntu 14.04 setup so I guess I won’t either for now. I did track it to the nvidia drivers, when using nouveau it didn’t show up in dmesg but the performance of the graphics card was poor. I do wish I could more easily switch to the Intel graphics card when running just the laptop display. Better battery life supposedly. I can switch to Intel but having to log out and back in is a pain. Locking up when connecting external monitors is a bigger pain.

What led me to understand Kernel 4.8 would “fix” it is this report:

[ 20.463084] ------------[ cut here ]------------
[ 20.463099] WARNING: CPU: 0 PID: 1567 at /build/linux-dcxD3m/linux-4.4.0/ubuntu/i915/intel_pm.c:3586 skl_update_other_pipe_wm+0x16c/0x180 [i915_bpo]()
[ 20.463100] WARN_ON(!wm_changed)
[ 20.463101] Modules linked in:
[ 20.463102] ctr ccm bbswitch(OE) bnep binfmt_misc nls_iso8859_1 arc4 nvidia_uvm(POE) snd_hda_codec_hdmi dell_led snd_hda_codec_realtek snd_hda_codec_generic snd_hda_intel i2c_designware_platform snd_hda_codec i2c_designware_core snd_hda_core snd_hwdep dell_wmi mxm_wmi snd_pcm nvidia_drm(POE) nvidia_modeset(POE) snd_seq_midi snd_seq_midi_event dell_rbtn iwlmvm snd_rawmidi dell_laptop dcdbas nvidia(POE) mac80211 snd_seq dell_smm_hwmon intel_rapl x86_pkg_temp_thermal intel_powerclamp coretemp kvm_intel uvcvideo videobuf2_vmalloc kvm videobuf2_memops videobuf2_v4l2 videobuf2_core snd_seq_device v4l2_common snd_timer videodev irqbypass media hid_multitouch btusb iwlwifi btrtl input_leds joydev serio_raw cfg80211 snd idma64 rtsx_pci_ms virt_dma soundcore memstick mei_me mei intel_lpss_pci shpchp processor_thermal_device
[ 20.463125] intel_soc_dts_iosf hci_uart btbcm int3403_thermal btqca btintel bluetooth intel_lpss_acpi intel_lpss wmi dell_smo8800 int3402_thermal int340x_thermal_zone int3400_thermal acpi_thermal_rel intel_hid acpi_als acpi_pad sparse_keymap kfifo_buf mac_hid industrialio parport_pc ppdev lp parport autofs4 btrfs xor raid6_pq drbg ansi_cprng algif_skcipher af_alg dm_crypt hid_logitech_hidpp dm_mirror dm_region_hash dm_log hid_logitech_dj usbhid rtsx_pci_sdmmc crct10dif_pclmul crc32_pclmul i915_bpo aesni_intel aes_x86_64 lrw gf128mul glue_helper ablk_helper cryptd intel_ips i2c_algo_bit drm_kms_helper syscopyarea psmouse sysfillrect sysimgblt fb_sys_fops nvme ahci drm rtsx_pci libahci i2c_hid hid pinctrl_sunrisepoint video pinctrl_intel fjes
[ 20.463146] CPU: 0 PID: 1567 Comm: Xorg Tainted: P W OE 4.4.0-31-generic #50-Ubuntu
[ 20.463147] Hardware name: Dell Inc. Precision 5510/08R8KJ, BIOS 1.2.14 08/31/2016
[ 20.463148] 0000000000000286 00000000e533d1cb ffff880892537938 ffffffff813f1143
[ 20.463149] ffff880892537980 ffffffffc0457c98 ffff880892537970 ffffffff81081102
[ 20.463150] ffff8808992bf000 ffff880891289d9c ffff8808992be000 ffff880891380378
[ 20.463152] Call Trace:
[ 20.463155] [<ffffffff813f1143>] dump_stack+0x63/0x90
[ 20.463158] [<ffffffff81081102>] warn_slowpath_common+0x82/0xc0
[ 20.463159] [<ffffffff8108119c>] warn_slowpath_fmt+0x5c/0x80
[ 20.463167] [<ffffffffc038969c>] skl_update_other_pipe_wm+0x16c/0x180 [i915_bpo]
[ 20.463174] [<ffffffffc0389836>] skl_update_wm+0x186/0x5f0 [i915_bpo]
[ 20.463186] [<ffffffffc04154ff>] ? intel_ddi_enable_transcoder_func+0x17f/0x260 [i915_bpo]
[ 20.463194] [<ffffffffc038d55e>] intel_update_watermarks+0x1e/0x30 [i915_bpo]
[ 20.463205] [<ffffffffc03f9571>] haswell_crtc_enable+0x321/0x8c0 [i915_bpo]
[ 20.463216] [<ffffffffc03f5f28>] intel_atomic_commit+0x5f8/0xdc0 [i915_bpo]
[ 20.463227] [<ffffffffc00c97de>] ? drm_atomic_check_only+0x18e/0x590 [drm]
[ 20.463234] [<ffffffffc00c9c17>] drm_atomic_commit+0x37/0x60 [drm]
[ 20.463238] [<ffffffffc0167b16>] drm_atomic_helper_set_config+0x76/0xb0 [drm_kms_helper]
[ 20.463245] [<ffffffffc00b8e42>] drm_mode_set_config_internal+0x62/0x100 [drm]
[ 20.463251] [<ffffffffc00bd362>] drm_mode_setcrtc+0x3d2/0x4f0 [drm]
[ 20.463256] [<ffffffffc00ae742>] drm_ioctl+0x152/0x540 [drm]
[ 20.463262] [<ffffffffc00bcf90>] ? drm_mode_setplane+0x1b0/0x1b0 [drm]
[ 20.463264] [<ffffffff81220c0f>] do_vfs_ioctl+0x29f/0x490
[ 20.463266] [<ffffffff8108e351>] ? __set_task_blocked+0x41/0xa0
[ 20.463267] [<ffffffff81090ce6>] ? __set_current_blocked+0x36/0x60
[ 20.463268] [<ffffffff81220e79>] SyS_ioctl+0x79/0x90
[ 20.463269] [<ffffffff81090f84>] ? SyS_rt_sigprocmask+0x74/0xc0
[ 20.463271] [<ffffffff8182db32>] entry_SYSCALL_64_fastpath+0x16/0x71
[ 20.463272] ---[ end trace 39089e4f3712369c ]---


Mounting Amazon Cloud Drive and Uploading Encrypted Data

12 Aug

I have about 5tb worth of files I need to backup online. With 5tb of data, solutions like Dropbox,, Google Drive, Microsoft OneDrive, etc. aren’t viable.  Technically Google Drive you could pay $10/tb so $50/month would get me 5tb of storage.  That’s still a lot just for backups.

There are “commercial” or “enterprise” solutions like Amazon S3 or Glacier:

– Standard S3 storage that’d cost $148 a month
– Standard – S3 Infrequent Access Storage that’d cost $62.50 a month  (wouldn’t work too well for me since I’d be accessing it frequently)
Glacier Storage that’d cost $35 a month (but I’d have difficulty accessing my data quickly/on-demand)

I know, I’m cheap, but then I discovered Amazon Cloud Drive, $60/year for “unlimited” storage. That’s essentially $5 a month, way cheaper than any of the above solutions, and you can easily access your files whenever you want.

There are a few caveats though, cloud drive does not offer standard protocols like WebDav/FTP/SFTP, they use some proprietary protocol but it is web driven. Luckily the development community has come up with solutions, reverse engineering the Amazon Cloud Drive protocol and making it where you can access. A friend of mine uses NetDrive with Windows to mount his Cloud Drive up to a drive letter. But I’m a Linux guy, so in steps acd_cli (aka acdcli).

ACDCLI technially, but it’s a python library/class that allows you to interact with Amazon Cloud drive using the “acdcli” python script. Essentially you can do things like “acdcli ls” (to list files) and “acdcli upload” (to upload a file) and “acd download” (to download a file) and “acd rm” (to delete a file)

More importantly, is the “acdcli mount” command, which allows you to mount your Amazon Cloud Drive to a path (like /amazon_cloud_drive). This uses FUSE, which is a pseudo-filesystem, it’s kind of like a regular linux mount but it’s done at the software layer rather than deeper in the kernel. This roughly translates to it not being as reliable/stable/fast as a regular mount, but it works. You won’t be able to use it like a “normal” mount/filesystem, don’t go expecting to do file/group ownership, permissions, symbolic links, etc. it’s limited, mostly it’s good for basic file storage/retrieval. Read more about it.

It’s fine though, all I intend to store on my Amazon Cloud Drive is photos, videos, backup files, etc. I don’t plan on putting anything advanced on it or interacting with it in any advanced capacity.

With acdcli you will first need to authenticate it to your Amazon account. You could run “acdcli init” but that kind of assumes it can launch a browser and point you at a specific URL. That URL turns out not to be so “lynx” friendly, I ended up copying/pasting that URL into a real browser on my computer. Essentially you authorized acdcli to access your amazon account and you will get a “oauth_data” file. Copy that file to your linux server into ~/.cache/acd_cli/oauth_data

Then run “acdcli sync”  this sync’s acdcli with Amazon Cloud Drive. acdcli kind of keeps a local listing of all the files that are on your cloud drive. I’m not sure why, maybe it’s a speed thing, so that it doesn’t have to talk to Amazon Cloud Drive every single time you do an “ls” or something. But just do it.

Then run “mkdir ~/amazon_cloud_drive”  followed by “acdcli mount -ao ~/amazon_cloud_drive”  and bingo. Now if you look in ~/amazon_cloud_drive/  you’ll see your files. Easy right?


The issue I had with Amazon Cloud Drive is when I read through their privacy policies, or their terms of service policy or whatever they call it. In the middle of it, hidden in legalize, is wording that let me to believe Amazon support engineers could look into your data. While I don’t have anything to hide, I also don’t want to expose all my personal files to just anybody. I’d rather Amazon not be able to see my data, so… encryption.  I discovered “encfs” thanks to another guide/article, encfs  is also a FUSE type of mount but it basically encrypts/decrypts on the fly from one directory to another directory.  You essentially point encfs to a “source” directory, where the encrypted files will be stored, and to a “destination” directory where you will work with those files like normal.

First just run “encfs” to setup a key and a passphrase for the key. You could technically not put a passphrase into the key since we won’t be uploading that key to the cloud drive, but I prefer to passphrase protect it just in case. Once you have the key, which is an xml file called encfs.xml,  you can do something like “export ENCFS6_CONFIG=’~/encfs.xml'”  or whatever.  Once you do that you can work with encfs more easily.

Now run “mkdir ~/acd” followed by “encfs ~/amazon_cloud_drive ~/acd” enter your passphrase and done!  Now you can place whatever files you want into ~/acd/  and it’ll be stored to your Amazon Cloud Drive encrypted.


So below you’ll see in “/amazon_cloud_drive” there are the Documents/Pictures/Videos folders Amazon automatically created for us but there are 2 folders that have strange characters, even the folders/filenames are encrypted.  When I look in /acd  I will see that those 2 encrypted folders are backups/ and photos/  etc. etc. it makes sense if you look at it/think about it. The bottom line is, it works. Amazon has no idea what those files or folders are, safe from prying eyes. Again, I have nothing to hide, it’s the principle of it all that gets to me. They don’t need to see photos of my children, or backups of a computer I had 3 years ago.

# acdcli mount /amazon_cloud_drive
# encfs mount /amazon_cloud_drive /acd
Password: ***********************

# ls /amazon_cloud_drive

# ls /amazon_cloud_drive/SoDvpAGY4PDKDLszKyLiG-3A
NvZd KedFXEq5dj9HcP2f6zaD4nXI/

# ls /acd

# ls /acd/photos


So what kind of speed am I getting? Well… right now I have 2 servers pushing my files to the Cloud Drive. One server is on a 1gbps connection (it’s in Germany and tends to have speed and packet loss issues) and it’s consistently uploading at around 30mbps. My other server is uploading to the Cloud Drive, at the same time, using a 100mbps connection (but in the U.S) and it’s able to consistently upload around 45mbps. So it’s pretty good in general. It is taking several weeks to upload 5 Gigabytes but I don’t mind. I’m using rsync to sync the data and afterwards I’ll have a cronjob run rsync once a day to sync only the changes.

For download speed, I’m getting close to double the upload speed. 60mbps from Germany and 90mbps from the U.S server. That 90mbps may be able to go faster but remember, I’m only on a 100/100 connection. So… not bad! Technically it’s fast enough to stream video off of. Theoretically you could put Plex on your server, point it to the ~/acd/ folder to where you personal family videos and photos are, and then you could access those personal photos/videos of your family from anywhere.


So it’s not all sunshine and rainbows. More than once my uploads have frozen/stopped. I’ve had to ctrl+c the rsync process, “umount -l” the /acd and /amazon_cloud_drive folders and kill any left over rsync/acdcli/rsync processes. Kind of a pain.  I’ve then had to run “acdcli sync” and then mount the folders up again and start the rsync process.

Also one time I was getting some error codes from Amazon’s servers when I did the “acdcli sync” command, some searching seemed to indicate that it’s a known issue and potentially something on Amazon’s side is blocking your authentication. The solution was simply to delete your oauth_data file and re-authorized acdcli using your browser and putting the new oauth_data file into place. I’ve had to do that once, but ever since I did that things do seem to be working a bit better. It could be just because I’m uploading so much data, relentlessly, consistently pushing data file after file after file. Maybe it’ll be more stable after all my files are up on the Amazon Cloud Drive. I imagine I’ll still need to update the oauth_data file once every month or two.

I really don’t know how Amazon is going to react to 5tb of storage, however I’ve read in forums about several other users who’ve stored 5tb, 10tb, 50tb and even 100tb of data on their cloud drive and haven’t gotten any complaints from Amazon. That’s insane, 100tb? Even I’d feel guilty about that. That 100tb was from a user was complaining the acdcli was limited to 100tb of storage, turns out he had close to 100tb of files stored on his cloud drive for many months. Wow.   So hopefully my measly 5tb won’t raise an eyebrow. But my general advice to anybody attempting the above setup, backup everything. Use Amazon Cloud Drive as a backup location, don’t keep your “only copy” of a file on Amazon Cloud Drive. According to their AUP (Acceptable Use Policies) is that they do reserve the right to cancel the account of any abusers. Remember, there’s no such thing as truly “unlimited”.  Also the fact that the files are encrypted may throw up some red flags, everyone’s natural reaction is “what are you hiding?”.  I suggest using a combination, anything non-important or generic, store in your “amazon_cloud_drive/” folder unencrypted. Anything you prefer to keep private, for whatever reasons, store in “acd/” which would be protected by encfs.  Also, DO NOT LOSE your encfs xml file, that contains the key to encrypt/decrypt your data. If you lose, your data is as good as useless.

How to get size of folders beginning with . (period)

28 Jul

Ok quick note. Annoying because

mintyfresh glitch-e6430 # du -sh home/glitch/
3.8G home/glitch/
mintyfresh glitch-e6430 #

Ok so, let’s figure out where it’s gone to:

mintyfresh glitch-e6430 # du -sh home/glitch/* | sort -h | tail -n 5
112K home/glitch/
1.4M home/glitch/
2.6M home/glitch/recording-1059.wav
15M home/glitch/base.apk
15M home/glitch/chef-repo.tar.bz2
mintyfresh glitch-e6430 #

Well that doesn’t make sense. None of those folders add up to gigabytes of data. So it must be a hidden directory, beginning with a . (period) but how do you get the disk space?

mintyfresh glitch-e6430 # du -sh home/glitch/.*
3.8G home/glitch/.
4.0K home/glitch/..
mintyfresh glitch-e6430 #

NOPE. It’s not as easy as you’d think to get the disk space of all the directories beginning with a period.

mintyfresh glitch-e6430 # cd home/glitch/
mintyfresh glitch # du -sh ./.*
3.8G ./.
4.0K ./..
mintyfresh glitch #
mintyfresh glitch # du -sh `ls -a`
3.8G .
4.0K ..
mintyfresh glitch #

NOPE.  I tried the above because I read more than one guide on the internet that says that should have worked. Not sure what I’m doing wrong but I cobbled together my own solution and I’m posting it here so I can reference it later, that is all. I’m sure I would eventually have found an article mentioning a similar, or maybe even better, solution.

mintyfresh glitch # du -sh .[a-z0-9]* | sort -h | tail -n 5
207M .dropbox
588M .vagrant.d
679M .config
858M .wine
1.1G .thunderbird
mintyfresh glitch #

There we go. Again I’m sure there’s probably a “better” way to do it, in Linux there always is, but this works for me.

Cable Modems and Wireless Routers

25 Jul

I was recently asked about the best Cable Modem + Wireless router all in one.

I am wholeheartedly against combination devices, in client’s homes (I used to do on site upgrades and repairs) I’ve seen the modem part go bad but the router work and vice versa. Also there are a LOT of good wireless routers out there that don’t offer an “integrated modem” option, and so you’d be missing out on some amazing wireless routers and/or the easy ability to easily upgrade in the future. Think of it like a T.V/VCR combination device, sure you can do it, and for a select few it may be an ok solution, but the majority of people are going to want to separate the devices.

Since I did about an hour of research, ’cause I’m a geek like that, I decided to drop the information here.

General Rule of Thumb

The reason I keep mentioning the date of this article is because I’m absolutely positive that within the next 6 months it will become outdated. But the general rule of thumb you can take from above is Motorola/Arris builds solid modems, and Asus builds solid wireless routers. Figure out your budget and devote $45-$90 to the modem, find the best motorola you can get in that price range. Then devote the rest to a wireless router, find the best Asus wireless router you can get in the $45+ price range (and make sure it’s supported by Merlin, even if you don’t use the Merlin software, it’s a good indication of well rounded, popular, community supported, Asus wireless routers. They won’t deal with weird one off models or low end devices with subpar performance, etc. If Merlin supports the router it’s a good indication it’s a good router overall).


Best Overall Budget Combination

The best all-around cable modem + wireless router combination IMHO (as of July 2016) is the Motorola/Arris SB6141 Cable Modem + Asus RT-N66U wireless router.


The SB6141 has 8 channels down and 4 channels up.Each channel supports 42.88 Mbit/s. so with this 8×4 configuration on this modem it is theoretically able to download up to 343 Mbit/s and upload up to 171 Mbit/s.  That doesn’t mean you’ll get that speed, you get what you pay for. That’s just what this modem is capable of doing.  So unless you pay Comcast/Suddenlink/etc. for more than 343 Mbit/s, you’ll be able to use this modem for years to come.

I found this modem for $40 + $3 shipping on Amazon used. New it’d run you something like $60 shipped. I don’t see any harm in a used modem, they don’t slow down over time or suffer any ill effects with age so if you can save money by going used, do it.

Wireless Router

802.11ac is the new hotness right now, but a lot of wireless devices don’t yet support it; they will in a year or two. My recommendation in general is to go with a cheapish, but top notch, 802.11n wireless router and in a year or so upgrade to a 802.11ac wireless router.  And that’s why the Asus RT-N66U is my choice. Now keep in mind this router came out in 2012/2013 but it’s gotten nothing but positive reviews. I personally prefer premium Asus Wireless Routers. There are cheapo Asus wireless routers not worth the time of day, avoid them. In general I look to the Merlin firmware to help decide on that most popular and most supported wireless routers.  Merlin is my favorite aftermarket firmware for Asus routers. They take the original Asus firmware and enhance it even more, adding more features and such, but it’s completely based on the Asus firmware and doesn’t require any weird or permanent modifications to the router. You simply flash the merlin firmware and you get all these new features, and if you don’t like it you can always flash the original firmware and you’re back to stock. But what this also tells me is that even after Asus stops releasing updates for the wireless router (they’re still actively updating/support the RT-N66U as of July 2016) you may be able to find aftermarket firmware to give new features to this old device.  Anyways

At this time, the supported devices for Merlin are:

  • RT-N66U
  • RT-AC56U
  • RT-AC66U
  • RT-AC68U & RT-AC68P (including revision C1)
  • RT-AC87U
  • RT-AC3200
  • RT-AC88U
  • RT-AC3100
  • RT-AC5300
  • RT-AC1900 & RT-AC1900P

It looks like Merlin has gone mostly AC, but they did choose to continue supporting the latest/last 802.11n router Asus made, the RT-N66U. So I chose this wireless router based on reviews and the fact that the community is still supporting it with advanced features and even bug fixes and Asus is still supporting it.

I found the router as cheap as $45 used and about $60 new. Personally I’ve used and abused the RT-AC68U wireless router for almost 2 years so far and in general it’s been a solid performer. I’ve got no doubt the RT-N66U will also be a solid wireless router for the masses.


So for $90-$120 you can get a SB6141 and RT-N66U combination and you’d be set for a while. In a year or two you may want to upgrade the wireless router but it’s up to you, if you don’t find you’re having any speed/performance issues and everything is great, you don’t have to.

Top of the Line Combination

That would be the Motorola/Arris SB6190 modem + Asus RT-AC5300


Ok so if you have money to burn and want “top of the line”, the best of the best, you could get the SB6190 modem for about $125 as of July 2016. That modem offers an insane 32 channels down and 8 channels up. So theoretically it can download up to 1.4 Gbit/s and upload up to 262 Mbit/s. That’s insanely awesome. My only concern is this thing is very expensive and it’s still just a DOCSIS 3.0 modem; with DOCSIS 3.1 right around the corner I’d rather spend that big money on one of those modems (once they become more widely available).  If you absolutely want a killer setup right now you could go with the SB6141 mentioned above for $45-$60 or you could compromise and get the SB6183 for about $90 which offers a 16×4 configuration. But if money’s no object, the SB6190 is the king at 32×8, but you’ll need a serious internet plan to even come close to seeing its speeds.

Don’t go and get this $120 modem if you have a 150 mbps connection, you would see zero internet performance difference between the SB6190 and the SB6183. I’d be willing to bet you may not even see a performance difference between the SB6190 ($125) and the SB6141 ($60).

If you have a 300 mbps connection you would most likely see a difference between the SB6141 ($60) and the SB6183 ($90) but I’d still bet you wouldn’t see a difference between the SB6183 ($90) and the SB6190 ($125).

Wireless Router

Well that would be, as of this writing (July of 2016) the Asus RT-AC5300. That’s a $380 wireless router, it’s a MONSTER of a wireless router. And yes, Merlin firmware supports it which makes it that much more insane.

  • Tri-band (dual 5 GHz, single 2.4 GHz) with the latest 802.11ac 4×4 technology for maximum throughput (5334 Mbps) and coverage (up to 5,000 sq. ft.)
  • MU-MIMO technology enables multiple compatible clients to connect at each client’s respective maximum speed
  • Built-in access to WTFast Gamers Private Network (GPN) of route-optimized servers ensures low, stable ping times for gaming
  • AiProtection Powered by Trend Micro provides multi-stage protection from vulnerability detection to protecting sensitive data
  • ASUS Smart Connect delivers consistent bandwidth by dynamically switching devices between 2.4 and 5 GHz bands based on speed, load and signal strength
  • ASUS Ranked “Highest Customer Satisfaction with Wireless Routers in the U.S.”- J.D. Power

Let’s just say this thing is an overkill and then some. I don’t even know what clients would support this beast, you’d have to upgrade the wireless cards in every device to even come close to using this things capabilities. No laptop (as of right now) has a built in wireless card that’s capable of fully utilizing this router.  It’s like drinking from a firehose. Anyways, if you want the best you could go with this, you’d be set for the next 4-6 years easy.


If you pay Cox/Charter/Comcast/Suddenlink for more than 500mbps and you have $505 or so laying around then go with the Arris SB6190 modem + Asus RT-AC5300 wireless router. It’s a truly magnificent combination of hardware.

Deon's Playground

Placing whatever interests me and more