Notes by woolf
Displaying keyword search results 1 - 11
Created by woolf on December 29, 2011 11:47:37
Last update: December 29, 2011 11:48:11
My Dell laptop wasn't able to use an external monitor after a week's vacation. The symptoms were:
No response when pressing Fn+F8 to swtich displays.
"No signal" on external monitor.
Bring up "Screen Resolution" dialog, only one monitor is avaiable.
Click "Advanced settings" in "Screen Resolution" dialog, Adapter Type displays "VgaSave".
There's no "Display adapters" section in Device Manager .
Solution: re-install the video display driver. My laptop came with Nvidia GPU so I reinstalled the Nvidia driver. Download the driver pack from Dell. The Windows 7 CAB file is about 1GB, which indludes all kinds of drivers.
Created by woolf on December 29, 2011 11:18:11
Last update: December 29, 2011 11:18:11
Use the expand command to extract files from a .cab file:
expand [-r] source [destination] [-d source.cab ... Option Description [-r] Renames expanded files. [destination] Specifies where files are to be expanded. If source is multiple files and -r is not specified, destination must be a directory. destination can consist of a drive letter and colon, a directory name, a file name, or a combination of any of these. [-d source.cab] Displays a list of files in the source location. Does not expand or extract the files. [-f:files] Specifies the files in a cabinet (.cab) file that you intend to expand. You can use wildcards (* and ?). source.cab Specifies the files to expand. source can consist of a drive letter and colon, a directory...
Created by woolf on July 30, 2011 13:03:48
Last update: October 24, 2011 07:52:42
Contrary to the DD-WRT router database , the Belkin F5D7231-4 v2000 cannot be flashed with TFTP . When I followed the TFTP procedures, I always got TTL=64 , never TTL=100 or TTL=128 , which is supposed to indicate that the router TFTPd is ready. I got network timeout when I tried to send the bin file anyway. The right way to flash the Belkin F5D7231-4 v2000 is to use the binary and Sercomm Utility provided by eko. Simply: Put the router in upgrade mode: unplug router, press reset button and keep it pressed while plugging in the power. Release it when lan leds turn off. Power and Connected led must blink . start the Sercomm Utility select the network interface connected to the router select...
Created by woolf on September 08, 2011 11:19:52
Last update: September 08, 2011 11:19:52
To check a command exists on PATH:
Use the return code of which :
which some_command &>/dev/null
[ $? -eq 0 ] || ...
For bash, use type -P :
type -P some_command &>/dev/null && echo "ome_comm...
or
check_path() {
if ! type -P $1 &> /dev/...
Created by woolf on August 07, 2011 15:17:12
Last update: August 07, 2011 15:17:12
Normally opkg installs packages from a repository which is specified in /etc/opkg.conf :
src/gz packages http://downloads.openwrt.org/backf...
What if you built a package locally and want to install that instead? Do this instead of setting up your own web server:
Copy your package ( .ipk file) to /tmp on the router:
$ scp mypackage_brcm63xx.ipk root@172.30.33.1:/tmp...
Copy the Packages file to the router:
$ scp Packages root@172.30.33.1:/var/opkg-lists/pa...
Log on the router, cd /tmp and install the local package:
root@OpenWrt:~# opkg install mypackage_brcm63xx.ip...
Created by woolf on July 05, 2011 15:38:52
Last update: July 05, 2011 15:39:55
By default VirtualBox enables one network adapter ("Adapter 1") with NAT. Connection from the guest OS to the outside world works natually when the guest network adapter is assigned an IP address by the VirtualBox DHCP server. Use VBoxManage to see a list of DHCP servers:
$ VBoxManage list dhcpservers NetworkName: H... The guest IP address is not visible from the outside world. If you need to access a server on the guest OS, you need to set up port forwarding in VirtualBox settings: Settings -> Network -> Adapter 1 -> Advanced -> Port Forwarding . Beware that on Linux/Unix, port forwarding may not work if you bind to a privileged port (port number < 1024) but you are not root. Bridged networking can be...
Created by woolf on July 03, 2011 19:29:45
Last update: July 05, 2011 08:28:06
eHow gave this command for defragging NTFS in Linux:
fsck -t ntfs --kerneldefrag /dev/XXX
which was rebuked by stack exchange . I believe the latter is right: there's no such thing!
Yes, there's a set of utilities called ntfsprogs (including ntfsresize, which is widely used), but defragmentation does not seem to be part of it.
Created by woolf on July 04, 2011 10:16:11
Last update: July 04, 2011 12:09:44
The following procedure will clear out the NVRAM and set dd-wrt back to default values:
With the unit powered on, press and hold the reset button on back of unit for 30 seconds
Without releasing the reset button, unplug the unit and hold reset for another 30 seconds
Plug the unit back in still holding the reset button a final 30 seconds
This procedure should be done before and after every firmware upgrade/downgrade.
The firmware writes information to the Nvram . A hard reset clears that information. If you don't clear it properly, parts of the old information be present with the new firmware, which can make it not operate properly.
Created by woolf on February 10, 2011 13:25:20
Last update: February 10, 2011 13:25:20
If Command Extensions are enabled (which is enabled by default), then there are several dynamic environment variables that can be expanded but which don't show up in the list of variables displayed by SET . These variable values are computed dynamically each time the value of the variable is expanded (but see example below). If the user explicitly defines a variable with one of these names, then that definition will override the dynamic one described below: %CD% - expands to the current directory string. %DATE% - expands to current date using same format as DATE command. %TIME% - expands to current time using same format as TIME command. %RANDOM% - expands to a random decimal number between 0 and 32767. %ERRORLEVEL% - expands to the...
Created by woolf on February 10, 2011 13:16:34
Last update: February 10, 2011 13:16:49
%PATH:str1=str2% would expand the PATH environment variable, substituting each occurrence of " str1 " in the expanded result with " str2 ". " str2 " can be the empty string to effectively delete all occurrences of " str1 " from the expanded output. " str1 " can begin with an asterisk, in which case it will match everything from the beginning of the expanded output to the first occurrence of the remaining portion of str1. %PATH:~10,5% would expand the PATH environment variable, and then use only the 5 characters that begin at the 11th (offset 10) character of the expanded result. If the length is not specified, then it defaults to the remainder of the variable value. If either number (offset or length) is negative,...
Created by woolf on February 12, 2009 03:13:27
Last update: February 12, 2009 03:13:27
The cygwin telnet client is contained in the inetutils package, which contains common utilities like telnet, ftp, rlogin, rcp, rsh, etc.