MarioNote

December 4, 2011

X11 Forwarding Fails When IPv6 is Disabled [Resolved]

Filed under: Ubuntu — mariojump @ 5:49 pm
Tags: , , ,

After disabling Ubuntu 11.10′s IPv6 by putting the following lines in /etc/sysctl.conf, I found that X11 Forwarding (ssh -X option) stopped working.
#Disable IPv6
net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1

Ubuntu Forum had an exact same case and workaround.

http://ubuntuforums.org/showthread.php?t=1649657

So, I put the following lines in remoet host’s /etc/ssh/sshd_config file.

$ cat /etc/ssh/sshd_config

………………………………

# Workaround to have X forwarding work when ipv6 is disabled
# http://ubuntuforums.org/showthread.php?t=1649657
AddressFamily inet

————-

It worked.

November 13, 2011

Linux rdesktop (Remote Desktop) with ClearType font smoothing enabled

Filed under: Linux,Ubuntu,Windows — mariojump @ 9:41 pm
Tags: , ,

I was looking for ways to make fonts look better in connecting to Windows from Linux via rdesktop.

The following page shows a great resolution/workaround.

http://katastrophos.net/andre/blog/2008/03/10/rdesktop-connect-to-windows-vista-with-cleartype-font-smoothing-enabled/

$ rdesktop -u mywinusername -k en-us -g 93% -x 80 -r sound myhostipaddress

Two other options than -x 80 are shown in the page above, -x 81 and -x 8f.  (Refer to the page above.)

 

 

September 19, 2011

Maven 2.2.1 – [WARNING] repository metadata for: ‘org.apache.maven.plugins’ could not be retrieved from repository

Filed under: Java,XML — mariojump @ 10:22 pm
Tags:

On Maven 2.2.1, I had trouble when executing, “mvn archetype:generate”, with the following errors.

[INFO] Searching repository for plugin with prefix: ‘archetype’.
[INFO] org.apache.maven.plugins: checking for updates from central
[WARNING] repository metadata for: ‘org.apache.maven.plugins’ could not be retrieved from repository: central due to an error: Error transferring file: Connection timed out
[INFO] Repository ‘central’ will be blacklisted

Finally, it turned out that the proxies section in settings.xml was not commented/uncommented properly. Windows XP Firewall or security software had nothing to do with the error.

August 27, 2011

Trang – Multi-format schema converter based on RELAX NG

Filed under: Java,Software Development,Ubuntu,XML — mariojump @ 10:53 am

Trang is a schema converter.

Install Trang on Ubuntu 10.04 LTS.
$ sudo apt-get install trang

This time, I used Trang to generate an XSD file from an XML file.

$ trang -I xml -O xsd InputXmlFile.xml OutputXSDFile.xsd

December 18, 2010

CVS Server Installation on Ubuntu Linux 10.04

Filed under: Linux memo,Ubuntu — mariojump @ 6:48 am

I installed CVS Server on Ubuntu 10.04.
CVS repository is copied from another machine, and it is placed in /opt/cvsroot .

Reference:
https://help.ubuntu.com/10.04/serverguide/C/cvs-server.html

# apt-get install xinetd
# apt-cache search git-cvs
# apt-get install git-cvs
# apt-cache search cvsps
# apt-get install cvsps

Edit /etc/xinetd.d/cvspserver .

# vi /etc/xinetd.d/cvspserver

The file now looks:

# cat /etc/xinetd.d/cvspserver
service cvspserver
{
port = 2401
socket_type = stream
protocol = tcp
user = root
wait = no
type = UNLISTED
server = /usr/bin/cvs
server_args = -f –allow-root /opt/cvsroot pserver
disable = no
}

# /etc/init.d/xinetd restart

Ensure CVS server is running.

# netstat -tap | grep cvs
tcp 0 0 *:cvspserver *:* LISTEN 11676/xinetd

December 8, 2010

Ubuntu Screen Resolution on Toshiba Satellite Pro 4600 with Trident XP

Filed under: Linux memo,Ubuntu — mariojump @ 9:48 pm

I installed Ubuntu Linux 10.04 on Toshiba Satellite Pro 4600 with Trident XP 16MB video, which is about 10 years old.
At first, the screen resolution was 800×600 on 1024×768 LCD.

Finding the following entry, I made /etc/X11/xorg.conf as shown below.
http://ubuntuforums.org/showthread.php?t=1354952

Then, the screen resolution became 1024×768.

$ cat /etc/X11/xorg.conf
Section “Monitor”
Identifier “Configured Monitor”
Option “DPMS” “true”
HorizSync 30.0-60.0
VertRefresh 50.0-70.0
EndSection

Section “Screen”
Identifier “Default Screen”
Monitor “Configured Monitor”
Device “Configured Video Device”
DefaultDepth 24
SubSection “Display”
Depth 24
Modes “1024×768″ “800×600″
EndSubSection

EndSection

September 4, 2010

Using AirTunes-AirMac Express from Ubuntu Linux

Filed under: Ubuntu — mariojump @ 9:22 pm

Install pulseaudio-module-raop
$ sudo apt-get install pulseaudio-module-raop

Install paprefs
$ sudo apt-get install paprefs

$ paprefs
In “Network Access Tab”, check both:
Make discoverable PulseAudio network sound devices available locally
Make discoverable Apple AirTunes sound devices available locally

System’s sound setting allows you to choose AirTunes sound device as output.

July 31, 2010

cron-like job setting on Windows XP with schtasks command

Filed under: Sample code,Windows — mariojump @ 4:57 am
Tags: ,

Task Scheduler GUI on Windows XP does not appear to allow us to set a job every 5 minutes.

Instead, schtasks command allows cron-like setting.

To set a job (a batch file) to run every 5 minutes, here’s a sample command.

C:\>schtasks /Create /SC MINUTE /MO 5 /TN yourjob_every5min.bat /TR C:\yourfolder\yourbatchfile.bat

July 3, 2010

Grub Error 18 – Debian Linux 5.05 (Lenny)

Filed under: Debian — mariojump @ 10:04 pm
Tags: , ,

When I installed Debian 5.05 (Lenny) onto a machine with an old motherboard, ASUS CUSL2-C (2000 or 2001 model), I got the following Grub error.

Grub Stage 1.5

Grub Loading, Please Wait
Error 18

My initial configuration was to use an entire HDD (one partition for the mountpoint / and another for swap).

According to the web page below, I made a separate /boot partition with 200MB, from the root (/) partition, placing the /boot at the first partition (/dev/hda1) of the HDD.

Then, base system installation was completed with GUI installation and Debian was successfully booted.

http://www.linuxquestions.org/questions/linux-hardware-18/grub-loading-please-wait-error-18-a-343280/

Motherboard: ASUS CUSL2-C (BIOS 1009, which is the latest release)
HDD: Hitachi HTS541616J9AT00 (160GB)

Incidentally, with this motherboard with Matrox G400 Video card, X window was not configured properly, and I am still researching.

June 4, 2010

Hadoop Installation Note (Standalone)

Filed under: Java,Linux,step-by-step — mariojump @ 10:30 pm
Tags: ,

This is a note when I installed Hadoop on a single machine (standalone).

I followed Hadoop Quick Start available at:
http://hadoop.apache.org/common/docs/r0.20.0/quickstart.html

Check Java version — Java 1.6.x is required, and Sun version is preferred. See:
http://hadoop.apache.org/common/docs/r0.20.0/quickstart.html

Download hadoop-0.20.2.tar.gz from:
http://hadoop.apache.org/mapreduce/releases.html#Download

$ tar xvzf hadoop-0.20.2.tar.gz

Skip rsync and ssh installation, as they are already available on the machine.

// Check the command usage:
$ cd hadoop-0.20.2
$ bin/hadoop
Usage: hadoop [--config confdir] COMMAND
where COMMAND is one of:
namenode -format format the DFS filesystem
secondarynamenode run the DFS secondary namenode
namenode run the DFS namenode
datanode run a DFS datanode
dfsadmin run a DFS admin client
mradmin run a Map-Reduce admin client
fsck run a DFS filesystem checking utility
fs run a generic filesystem user client
balancer run a cluster balancing utility
jobtracker run the MapReduce job Tracker node
pipes run a Pipes job
tasktracker run a MapReduce task Tracker node
job manipulate MapReduce jobs
queue get information regarding JobQueues
version print the version
jar run a jar file
distcp copy file or directories recursively
archive -archiveName NAME * create a hadoop archive
daemonlog get/set the log level for each daemon
or
CLASSNAME run the class named CLASSNAME
Most commands print help when invoked w/o parameters.

$ mkdir input
$ cp conf/*.xml input
$ bin/hadoop jar hadoop-*-examples.jar grep input output ‘dfs[a-z.]+’
Error: JAVA_HOME is not set.

$ /usr/java/latest/bin/java -version
java version “1.6.0_16″

$ export JAVA_HOME=/usr/java/latest
[added this line in the .bashrc]
Reference: http://www.atmarkit.co.jp/fjava/special/distributed03/distributed03_1.html

Try again:
$ bin/hadoop jar hadoop-*-examples.jar grep input output ‘dfs[a-z.]+’

No error message is shown this time.
$ cat output/*
1 dfsadmin

Next Page »

Theme: Rubric. Blog at WordPress.com.

Follow

Get every new post delivered to your Inbox.