Archive for the ‘Linux’ Category

(Open)Solaris, Linux and FreeBSD tunnelbroker.net IPv6 setup

Tuesday, December 1st, 2009

After you create a Regular Tunnel at Hurricane Electric’s tunnelbroker.net you will receive the following informations:

Server IPv4 Address
Server IPv6 Address
Client IPv4 Address
Client IPv6 Address
Routed /64

Solaris and OpenSolaris IPv6 tunnel setup

Create /etc/hostname6.ip.tun0 file:
tsrc Client_IPv4_Address tdst Server_IPv4_Address up
addif Client_IPv6_Address Server_IPv6_Address up

Add the permanent IPv6 default gateway:
route -p add -inet6 default Server_IPv6_Address

(Tested on Solaris 10 5/09 and 10/09, OpenSolaris 2009.06 and 2010.02 preview snv_127)

Linux (RHEL / Fedora / CentOS) IPv6 tunnel setup

Create /etc/sysconfig/network-scripts/ifcfg-sit1 file:

DEVICE=sit1
BOOTPROTO=none
ONBOOT=yes
IPV6INIT=yes
IPV6TUNNELIPV4=Server_IPv4_Address
IPV6TUNNELIPV4LOCAL=Client_IPv4_Address
IPV6ADDR=Client_IPv6_Address/64

Add the following to /etc/sysconfig/network file:

NETWORKING_IPV6=yes
IPV6_DEFAULTDEV=sit1

(Tested with Fedora 11 and 12, CentOS 5.3 and 5.4)

FreeBSD IPv6 tunnel setup

Add the following lines to /etc/rc.conf file:

gif_interfaces="gif0"
gifconfig_gif0="Client_IPv4_Address Server_IPv4_Address"
ipv6_enable="YES"
ipv6_network_interfaces="lo0 gif0"
ipv6_ifconfig_gif0="Client_IPv6_Address prefixlen 128"
ipv6_defaultrouter="Server_IPv6_Address"

(Tested with FreeBSD 6.4)

Installing Fedora 12 PV domU guest on xVM dom0 OpenSolaris

Friday, November 20th, 2009

Create a 10 GB ZVOL for storage:
pfexec zfs create -V 10g rpool/f12d0

Install Fedora 12 domU:
pfexec virt-install -n f12 -r 512 --vcpus=4 -f /dev/zvol/dsk/rpool/f12d0 -b e1000g0 --os-type=linux -p --nographics --os-variant=fedora11 -l http://fedora-12-mirror/fedora/linux/releases/12/Fedora/i386/os/

-n f12 – domU’s name
-r 512 – allocate 512 MB memory
–vcpus=4 – number of virtual CPUs allocated (make sure this number is lower or equal to the number of CPUs available)
-f /dev/zvol/dsk/rpool/f12d0 – ZVOL block device
-b e1000g0 – bridged networking to e1000g0 interface
-p – paravirtualized guest
–os-variant=fedora11 – “hack” until fedora12 OS-Variant will be integrated into xVM
-l http://fedora-12-mirror/fedora/linux/releases/12/Fedora/i386/os/ – replace fedora-12-mirror with a near Fedora 12 mirror, replace i386 with x86_64 for 64-bit domU

After you bring up the network, do a VNC installation.
Until xVM supports ext4 boot, make sure to create an ext3 /boot partition (or just a big ext3 / filesystem)

After installation, start the domU:
pfexec xm start -c f12
You will be presented the pygrub menu, just press Enter to boot.

Log into the domU and change the default timeout=0 to a different value (e.g. 5 seconds) in /boot/grub/grub.conf. Now you can use virsh start / shutdown commands.

To auto-start the guest on host boot:
virsh autostart f12

Tested on OpenSolaris 2010.02 preview snv_127.

Fedora 12 PPTP server

Friday, November 20th, 2009

I’ve build a Fedora 12 Poptop rpm:

pptpd-1.3.4-1.fc12.i386.rpm MD5 bdab201d70e78abe40f873d71880f718
pptpd-1.3.4-1.fc12.src.rpm MD5 ebd64f47b0a40a7585e22a11cc4e2890

If you get this error message:
Plugin /usr/lib/pptpd/pptpd-logwtmp.so is for pppd version 2.4.3, this is 2.4.4
just comment out logwtmp option in /etc/pptpd.conf and restart pptpd with service pptpd restart.

Username/password pairs used for pptp authentication should be placed in /etc/ppp/chap-secrets
# client server secret IP addresses
username * password

To supply a DNS server to PPTP clients, just add them to /etc/ppp/options.pptpd like ms-dns A.B.C.D.

To configure local and remote PPTP client’s IP address modify localip and remoteip options in /etc/pptpd.conf.

To enable pptp server at startup run chkconfig pptpd on.

$20 Xen VPS Gandi vs. Linode vs. Slicehost

Thursday, September 17th, 2009
Gandi Linode Slicehost
Plan 1 Share Linode 360 256 slice
Price 14.35 EUR
(~20 USD)
19.95 USD 20 USD
RAM 256MB 360MB 256MB
Storage 8GB
(3 OS + 5 Data)
16GB 10GB
Bandwidth 5 Mbit 200GB 100GB
My VPS Location Paris, France
Europe
Dallas, TX
USA
St. Louis, MI
USA
My VPS CPU Quad-Core AMD Opteron(tm) Processor 8346 HE Intel(R) Xeon(R) CPU L5420 @ 2.50GHz Dual Core AMD Opteron(tm) Processor 270
My VPS vCPUs 1 4 4
My VPS OS CentOS 5.3 CentOS 5.3 CentOS 5.3
My VPS Buffered disk reads 10.48 MB/sec 73.77 MB/sec 60.86 MB/sec
My VPS OGR-NG Benchmark 23,608,069 nodes/sec 40,910,174 nodes/sec 17,593,557 nodes/sec
My VPS RC5-72 Benchmark 7,703,097 keys/sec 9,297,850 keys/sec 8,585,510 keys/sec

Linux /proc/cpuinfo flags

Monday, July 20th, 2009

fpu – Onboard FPU
vme – Virtual Mode Extensions
de – Debugging Extensions
pse – Page Size Extensions
tsc – Time Stamp Counter
msr – Model-Specific Registers
pae – Physical Address Extensions
mce – Machine Check Architecture
cx8 – CMPXCHG8 instruction
apic – Onboard APIC
sep – SYSENTER/SYSEXIT
mtrr – Memory Type Range Registers
pge – Page Global Enable
mca – Machine Check Architecture
cmov – CMOV instructions (plus FCMOVcc, FCOMI with FPU)
pat – Page Attribute Table
pse36 – 36-bit PSEs
pn – Processor serial number
clflush – CLFLUSH instruction
dts – Debug Store
acpi – ACPI via MSR
mmx – Multimedia Extensions
fxsr – FXSAVE/FXRSTOR, CR4.OSFXSR
sse – SSE
sse2 – SSE2
ss – CPU self snoop
ht – Hyper-Threading
tm – Automatic clock control
ia64 – IA-64 processor
pbe – Pending Break Enable

syscall – SYSCALL/SYSRET
mp – MP Capable
nx – Execute Disable
mmxext – AMD MMX extensions
fxsr_opt – FXSAVE/FXRSTOR optimizations
pdpe1gb – GB pages
rdtscp – RDTSCP
lm – Long Mode (x86-64)
3dnowext – AMD 3DNow! extensions
3dnow – 3DNow!
k8 – Opteron, Athlon64
k7 – Athlon
constant_tsc – TSC ticks at a constant rate
up – smp kernel running on up
pebs – Precise-Event Based Sampling
bts – Branch Trace Store
nonstop_tsc – TSC does not stop in C states
pni – SSE-3
pclmulqdq – PCLMULQDQ instruction
dtes64 – 64-bit Debug Store
monitor – Monitor/Mwait support
ds_cpl – CPL Qual. Debug Store
vmx – Hardware virtualization
smx – Safer mode
est – Enhanced SpeedStep
tm2 – Thermal Monitor 2
ssse3 – Supplemental SSE-3
cid – Context ID
fma – Fused multiply-add
cx16 – CMPXCHG16B
xptr – Send Task Priority Messages
pdcm – Performance Capabilities
dca – Direct Cache Access
sse4_1 – SSE-4.1
sse4_2 – SSE-4.2
x2apic – x2APIC
aes – AES instructions
xsave – XSAVE/XRSTOR/XSETBV/XGETBV
avx – Advanced Vector Extensions
hypervisor – Running on a hypervisor
lahf_lm – LAHF/SAHF in long mode
cmp_legacy – If yes HyperThreading not valid
svm – Secure virtual machine
extapic – Extended APIC space
cr8legacy – CR8 in 32-bit mode
abm – Advanced bit manipulation
sse4a – SSE-4A
ibs – Instruction Based Sampling
sse5 – SSE-5
skinit – SKINIT/STGI instructions
wdt – Watchdog timer

EU VPS wanted

Saturday, November 3rd, 2007

I am still searching a reasonable-priced Linux Xen VPS located in EU (256 MB RAM, few GB storage).

New off-site backup solution – rsync.net

Saturday, June 16th, 2007

I signed up with rsync.net for an off-site filesystem. Opted for geo-redundant version (automated nightly replication to other site) located in Zurich, Switzerland. Very fast speed from Europe and Qatar, good speed with US hosts. Very easy to use from Mac OS X, FreeBSD, Linux and Windows (rsync, ftp, scp, sftp, ssh, WebDAV). Direct integration in Finder, just use “Connect to Server” and enter the hostname address with https. On Linux and FreeBSD 6.x sshfs works like a charm. Easy to install on FreeBSD using ports, just cd /usr/ports/sysutils/fusefs-sshfs and run make install clean.

SiI 3112 and linux

Friday, May 12th, 2006

2.6.16.16 with CONFIG_BLK_DEV_SIIMAGE=y and CONFIG_SCSI_SATA_SIL=y

ata2: translated ATA stat/err 0x51/04 to SCSI SK/ASC/ASCQ 0xb/00/00
ata2: status=0x51 { DriveReady SeekComplete Error }
ata2: error=0x04 { DriveStatusError }
ata2: no sense translation for status: 0x51
ata2: translated ATA stat/err 0x51/00 to SCSI SK/ASC/ASCQ 0x3/11/04
ata2: status=0x51 { DriveReady SeekComplete Error }
ata2: no sense translation for status: 0x51
ata2: translated ATA stat/err 0x51/00 to SCSI SK/ASC/ASCQ 0x3/11/04
ata2: status=0x51 { DriveReady SeekComplete Error }
ata2: no sense translation for status: 0x51
ata2: translated ATA stat/err 0x51/00 to SCSI SK/ASC/ASCQ 0x3/11/04
ata2: status=0x51 { DriveReady SeekComplete Error }
ata2: no sense translation for status: 0x51
ata2: translated ATA stat/err 0x51/00 to SCSI SK/ASC/ASCQ 0x3/11/04
ata2: status=0x51 { DriveReady SeekComplete Error }
ata2: no sense translation for status: 0x51
ata2: translated ATA stat/err 0x51/00 to SCSI SK/ASC/ASCQ 0x3/11/04
ata2: status=0x51 { DriveReady SeekComplete Error }
ata2: no sense translation for status: 0x51
ata2: translated ATA stat/err 0x51/00 to SCSI SK/ASC/ASCQ 0x3/11/04
ata2: status=0x51 { DriveReady SeekComplete Error }

dmesg:

libata version 1.20 loaded.
sata_sil 0000:00:0c.0: version 0.9
ACPI: PCI Interrupt Link [LNKD] enabled at IRQ 11
PCI: setting IRQ 11 as level-triggered
ACPI: PCI Interrupt 0000:00:0c.0[A] -> Link [LNKD] -> GSI 11 (level, low) -> IRQ
 11
ata1: SATA max UDMA/100 cmd 0xD0802080 ctl 0xD080208A bmdma 0xD0802000 irq 11
ata2: SATA max UDMA/100 cmd 0xD08020C0 ctl 0xD08020CA bmdma 0xD0802008 irq 11
ata1: SATA link up 1.5 Gbps (SStatus 113)
ata1: dev 0 cfg 49:2f00 82:746b 83:7f01 84:4023 85:7469 86:3c01 87:4023 88:407f
ata1: dev 0 ATA-7, max UDMA/133, 488397168 sectors: LBA48
ata1: dev 0 configured for UDMA/100
scsi0 : sata_sil
ata2: SATA link up 1.5 Gbps (SStatus 113)
ata2: dev 0 cfg 49:2f00 82:746b 83:7f01 84:4023 85:7469 86:3e01 87:4023 88:407f
ata2: dev 0 ATA-7, max UDMA/133, 488397168 sectors: LBA48
ata2: dev 0 configured for UDMA/100
scsi1 : sata_sil
  Vendor: ATA       Model: WDC WD2500KS-00M  Rev: 02.0
  Type:   Direct-Access                      ANSI SCSI revision: 05
  Vendor: ATA       Model: WDC WD2500JS-55N  Rev: 10.0
  Type:   Direct-Access                      ANSI SCSI revision: 05
SCSI device sda: 488397168 512-byte hdwr sectors (250059 MB)
sda: Write Protect is off
sda: Mode Sense: 00 3a 00 00
SCSI device sda: drive cache: write back
SCSI device sda: 488397168 512-byte hdwr sectors (250059 MB)
sda: Write Protect is off
sda: Mode Sense: 00 3a 00 00
SCSI device sda: drive cache: write back
 sda: sda1
sd 0:0:0:0: Attached scsi disk sda
SCSI device sdb: 488397168 512-byte hdwr sectors (250059 MB)
sdb: Write Protect is off
sdb: Mode Sense: 00 3a 00 00
SCSI device sdb: drive cache: write back
SCSI device sdb: 488397168 512-byte hdwr sectors (250059 MB)
sdb: Write Protect is off
sdb: Mode Sense: 00 3a 00 00
SCSI device sdb: drive cache: write back
 sdb: sdb1
sd 1:0:0:0: Attached scsi disk sdb

Problems with SiI 3112 SATA RAID controller

Friday, May 12th, 2006
ata2: no sense translation for status: 0x51
ata2: translated ATA stat/err 0x51/00 to SCSI SK/ASC/ASCQ 0x3/11/04
ata2: status=0x51 { DriveReady SeekComplete Error }
ata2: no sense translation for status: 0x51
ata2: translated ATA stat/err 0x51/00 to SCSI SK/ASC/ASCQ 0x3/11/04
ata2: status=0x51 { DriveReady SeekComplete Error }

2.4.33-pre3 kernel, CONFIG_SCSI_SATA_SIL driver, EIO DM-8301R SATA RAID card:

libata version 1.20 loaded.
PCI(00:0c.0): version 0.9
ata1: SATA max UDMA/100 cmd 0xD080C080 ctl 0xD080C08A bmdma 0xD080C000 irq 11
ata2: SATA max UDMA/100 cmd 0xD080C0C0 ctl 0xD080C0CA bmdma 0xD080C008 irq 11
ata1: dev 0 cfg 49:2f00 82:746b 83:7f01 84:4023 85:7469 86:3c01 87:4023 88:407f
ata1: dev 0 ATA-7, max UDMA/133, 488397168 sectors: LBA48
ata1: dev 0 configured for UDMA/100
ata2: dev 0 cfg 49:2f00 82:746b 83:7f01 84:4023 85:7469 86:3e01 87:4023 88:407f
ata2: dev 0 ATA-7, max UDMA/133, 488397168 sectors: LBA48
ata2: dev 0 configured for UDMA/100
scsi0 : sata_sil
scsi1 : sata_sil
  Vendor: ATA       Model: WDC WD2500KS-00M  Rev: 02.0
  Type:   Direct-Access                      ANSI SCSI revision: 05
  Vendor: ATA       Model: WDC WD2500JS-55N  Rev: 10.0
  Type:   Direct-Access                      ANSI SCSI revision: 05
Attached scsi disk sda at scsi0, channel 0, id 0, lun 0
Attached scsi disk sdb at scsi1, channel 0, id 0, lun 0

Partial solution to DMA/write errors – BIOS upgrade:

http://www.siliconimage.com/search/searchresults.aspx?keyword=3112+bios

(4.2.76 at the time of writing)

ip_conntrack

Friday, November 18th, 2005

Learned the hard way: NEVER COMPILE ip_conntrack into the Linux kernel… :-)