Archive | Howtology RSS for this section

Connecting WWAN Modem in Linux

As of this writing Linux support about this type of modem isn’t really good. GUI Network Manager doesn’t know such device. You need to configure it manually (in console). The solution that works for me.
First

$ echo -e “AT^NDISDUP=1,1,\”your_APN_name\”\r” > /dev/ttyUSB0

This command will connect the stick to LTE network.

Assuming:
– You have installed usb_modeswitch package
– the modem created /dev/ttyUSB0
– your modem has no qmi and no mbim. It just works with AT command.

Then

$ su -c dhclient wwan0

This command will acquire IP address for the wwan0 interface.

Various notes:
– When this device connected to internet, your network manager software will recognized the connection as ‘Wired Connection’.
– if your WWAN modem is QMI device, you probably need to use qmcli to configure your device.
– if your WWAN modem is MBIM device, you probably need to use mmcli to configure your device.

Source:
How to enable broadband connection with Huawei E3372h on Ubuntu Server
How To Use LTE modem in QMI mode for WAN connection
What is libqmi?
What is libmbim?

How to enable the Ribbon UI [MS Office style] in LibreOffice

To enable the new Ribbon UI
First:
Tools > Options > LibreOffice > Advanced > Enable experimental features (may be unstable)
LibreOffice will then need to restart. After the restart:
View > Toolbar Layout > Notebookbar

To revert the changes
Click some strange icon in top left corner > Options > Advanced > uncheck “Enable experimental features (may be unstable)”

Source:
LibreOffice 5.3 Ships with Experimental Office-Like Ribbon UI
Microsoft Office Ribbon UI Is Coming to LibreOffice

Using dd to Create a Bootable USB Linux System from .iso File

This short tutorial assumes you build the bootable USB from a Linux system (not from Windows or Mac).
– First make an hybrid ISO from your distro .iso file using isohybrid tool. This step isn’t required if your .iso  are already a hybrid.

$ isohybrid your_iso_file.iso

You might see an error when issuing the command

Warning: more than 1024 cylinders (1620).Not all BIOSes  will be able to boot this device

Don’t worry about it.The warning refers to very old BIOSes.

– Then use dd to write that hybrid ISO to your USB drive.

$ dd if=your_iso_file.iso of=/dev/sdX

Replace the your_iso_file with the name of your .iso file.
Replace the /dev/sdX with the path to the USB drive. Note: the path to the USB drive (/dev/sdX) you want to write to must not contain a partition letter.  So it should look like /dev/sdb not /dev/sdb1.
Also, the dd command does not provide indicator for progression while it is running in the console. Just wait for a little while.

Source:
Create USB Boot Stick | PCLinuxOS forum
HOWTO: Create a bootable Linux Media using the dd Command | Toolbox.com

Youtube’s HTML5 Player and 1080p in Firefox(Linux)

1.Activating HTML5 player
As of this writing it is not activated by default in Firefox. It has something to do about Media Source Extensions, not activated by default in Firefox.
Go to https://www.youtube.com/html5 and “Select the HTML5 player” to activate the HTML5 player.

2.Get the 1080p stuff
To get Full HD resolution you need to enable both Media Source Extensions in general and MSE + WebM in Firefox.
-Type about:config in the address and Click “I’ll be careful, I promise”
– Type mediasource in searchbox. Double-click both media.mediasource.enabled and media.mediasource.webm.enabled in order to change their value to “true”. Read More…

Solution for Virtualenv Error : ‘Unable to Execute bla bla Permission Denied ‘

So I got this error when creating a virtualenv on a different partition other than my /home folder.

ERROR: The executable myenv/bin/python3.4 could not be run: [Errno 13] Permission denied

Turns out this problem related to the default permission when creating a partition which didn’t enable exec option on my partition. So, I enable the exec option by editing /etc/fstab .
Before

# Entry for /dev/sda7 :
/dev/sda7 /media/sda7 ext4 user 1 2

After

# Entry for /dev/sda7 :
/dev/sda7 /media/sda7 ext4 user,exec 1 2

Note the addition of ‘exec’.

Reference:
strange permissions problems for virtualenv python executable (lubuntu-12.10) | StackOverFlow

How to pip via Proxy Server

Just tell pip to use the proxy via –proxy option.

$ pip install --proxy username:password@proxyserver:port package_name 

Reference:
How to get pip to work behind a proxy server | StackOverflow

Turn on Tracking Protection in Firefox to Make Pages Load Faster

set privacy.trackingprotection.enabled to true

To turn on Tracking Protection in Firefox:

  • Type in about:config in the location bar and hit enter.
  • You’ll see a warning about possibly voiding your warranty. Hit “I’ll be careful, I promise!” to continue.
  • Search for privacy.trackingprotection.enabled.
  • Double-click that to toggle the value to true.

Former Mozilla software engineer Monica Chew and Computer Science researcher Georgios Kontaxis took a look at the top 200 news sites (according to Alexa) and found a median 44% reduction in page load time, as well as a 39% reduction in data usage when the optional Tracking Protection is turned on.

Tracking Protection actively blocks domains known to track users. You might not see huge performance benefits for all sites, depending on how much each site relies on third-party content and similar extras from tracking domains. Still, with a range of between 20% and 90% decreased page load times according to the study—and better privacy control—it’s worth a shot.

Source:
Turn on Tracking Protection in Firefox to Make Pages Load 44% Faster | Lifehacker