networking

The Contingency

0

UPDATE: given that I have now upgraded the motherboard, and it now works, these problems are now rendered moot. However for those interested, that eliminates the HDD and IPFire out as the problem source. My guess is that it was caused by the 3512 card not working correctly, be it in hardware or software.

Ok so maybe buying a whole new router was a little rash given I have a problem that could potentially be solved by other means.

Here’s the situation and the problem:

The Players:

Linux box running IPFire with the following specs:

CPU: Intel Pentium 4 1.6 Ghz

RAM: 512MB generic DDR (i think)

PSU: Generic 350w or something of the like

MOBO: Intel 800 Series something-a-rather

HDD: Western Digital WD1600 160GB IDE

MEDIA HDD: Western Digital WD20 2TB SATA2

NET: 2x TP-Link 1Gbps Ethernet PCI cards (1 for LAN, 1 for WAN) running CAT6 cabling

SATA Card: Ritmo PCI to SATA1 w/Silicon Image Sil3512 SATALink chip

Notes:

  • The media drive is new, there’s no SMART errors, no issues hardware related from what I can tell.
  • It is connected via a PCI Silicon Image 3512 SATALink 1.5Gbps SATA1 controller card. Powered by a molex –> SATA power converter.

The Problem:

I can successfully copy files via any method to the media drive, however I cannot read the resulting files. The transfer usually goes on for a second or so at full speed and then suddenly drops to <100KB/s and finally dies with an error message. I’ve tried multiple files, all fail.

I have finally found some useful information about the errors im getting in relation to ata2.00: error: { ICRC UNC IDNF ABRT }

(see below for full kernel message)

According to https://ata.wiki.kernel.org/index.php/Libata_error_messages

  • ICRC = Interface CRC error during Ultra DMA transfer (which is likely caused by power issues or bad driver instructions)
  • UNC = Uncorrectable error (bad sectors)
  • IDNF = Requested address was not found
  • ABRT = Command aborted

Looks to me that the first error causes the others. But then again who knows, I could just be that unlucky.

 

18:34:18 Kernel.Info	kernel: ata2: EH complete
18:34:18 Kernel.Info	kernel: ata2.00: configured for UDMA/33
18:34:18 Kernel.Info	kernel: ata2: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
18:34:18 Kernel.Info	kernel: ata2: hard resetting link
18:34:18 Kernel.Error	kernel: ata2.00: error: { ICRC UNC IDNF ABRT }
18:34:18 Kernel.Error	kernel: ata2.00: status: { Busy }
18:34:18 Kernel.Error	kernel:          res ff/ff:ff:ff:ff:ff/ff:ff:ff:ff:ff/ff Emask 0x2 (HSM violation)
18:34:18 Kernel.Error	kernel: ata2.00: cmd 25/00:00:1f:03:b6/00:01:3e:00:00/e0 tag 0 dma 131072 in
18:34:18 Kernel.Error	kernel: ata2.00: failed command: READ DMA EXT
18:34:18 Kernel.Error	kernel: ata2.00: exception Emask 0x0 SAct 0x0 SErr 0x0 action 0x6 frozen
18:34:18 Kernel.Debug	kernel: ata2: drained 32768 bytes to clear DRQ.
18:34:17 Kernel.Info	kernel: ata2: EH complete
18:34:17 Kernel.Info	kernel: ata2.00: configured for UDMA/33
18:34:17 Kernel.Info	kernel: ata2: SATA link up 1.5 Gbps (SStatus 113 SControl 310)
18:34:17 Kernel.Info	kernel: ata2: hard resetting link
18:34:17 Kernel.Error	kernel: ata2.00: error: { ICRC UNC IDNF ABRT }
18:34:17 Kernel.Error	kernel: ata2.00: status: { Busy }
18:34:17 Kernel.Error	kernel:          res ff/ff:ff:ff:ff:ff/ff:ff:ff:ff:ff/ff Emask 0x2 (HSM violation)
18:34:17 Kernel.Error	kernel: ata2.00: cmd 25/00:00:1f:d0:b5/00:01:3e:00:00/e0 tag 0 dma 131072 in
18:34:17 Kernel.Error	kernel: ata2.00: failed command: READ DMA EXT
18:34:17 Kernel.Error	kernel: ata2.00: exception Emask 0x0 SAct 0x0 SErr 0x0 action 0x6 frozen
18:34:17 Kernel.Debug	kernel: ata2: drained 32768 bytes to clear DRQ.

Oh and here’s my mtab entry:

/dev/sda1 /mnt/media xfs rw,noatime,allocsize=512m,logbufs=8 0 0

What I’ve tried:

  • Rebooting the machine (lol)
  • Copying via SCP over SSH, RSync, SAMBA
  • Reseating the SATA controller card
  • Using a different PCI slot
  • Changing the SATA cable over
  • Reseating the Molex -> SATA power connector
  • Using the other port on the controller
  • Using the OPT1 jumper position on the HDD ensuring SATA1 compatibility (worked without it anyway)
  • acpi=off noapic options in GRUB
  • Using a non smp kernel
  • Reformatting
  • Recopying all media files (1.4TB .. .took bloody ages too)
  • Formatting as EXT4
  • Formatting as XFS (and this is the current file system)
  • Updating the controller cards’ BIOS chip (didn’t need it)

Causes?

To be honest, I’m at a loss.

The only possiblities that remain (that I can think of atm) are:

  1. the modified IPFire kernel doesn’t support what I’m trying to do.
  2. the 3512 controller isn’t properly processing DMA commands
  3. lack of power from the PSU (though I can’t imagine why that would only prevent reads)
  4. old age/generally incompatible
  5. motherboard failure
  6. HDD failure (highly unlikely + I have had no issue reformatting and SMART doesn’t report any issues)

 

Fixes?

Cheap options:

  • Check media drive with SpinRite on another machine, ensuring all sectors are clean and not ‘bad’
  • New controller card
  • If not, new power supply

Expensive options:

  • New machine using old hardware (just need CPU/Power Supply -the rest I already have) $76
  • New machine (excluding the case), upgraded hardware, gutsier processor, integrated LAN and SATA2 ports.  $148 (cheapest AMD) to $184 (best Intel)

 

 

 

New Router

0

As good as the old machine I got from TAFE, the router is in need of an upgrade.

Now normally I need no reason to do this, but for the sake of convincing myself my reasons are as follows:

1) The current computer isn’t optimised for power efficiency (newer motherboards are surely more efficient)

2) The power supply seems to be making funny noises (could just need a dusting but meh)

3) It currently doesn’t natively support 1Gbps LAN (needs PCI addon card)

and finally:

4) It doesn’t have SATA, requiring the use of another PCI card to include the media backup drive in my setup (which is currently only working in one direction).

So here’s what I have in mind:

 

CPU:

AMD Intel
Cheapest:Sempron 140 2.8GhzSingle Core 45w x64 Cheapest:Celeron Socket 775 E3400 Dual-core 2.6Ghz 65w
$31 $47
Ideal:Athlon II X2 255 Dual-Core 3.10Ghz 65w Ideal: Core 2 Duo E6600 3.06Ghz Dual-Core 65w
$61 $67

 

Motherboard:

AMD Intel AMD Old Motherboard
ASUS M4A78LT-M-LE

Socket AM3+ Integrated GFX + DDR3 Ram + 1x 1Gbps LAN 

ASUS P5G41T-M-LX Socket 775+Integrated GFX + DDR3 Ram + 1x 1Gbps LAN  Gigabyte GA-M56S-S3 Socket AM2 (supports AM3 @ 2000MT/s)+ DDR2 Ram + 1x 1Gbps LAN
$55 $59  $0

 

 

 

 

 

 

 

 

 

 

Memory:

Kingston 2GB DDR3-1333

$17

 

Power Supply:

Vantec ION2 CAN-460C 460Watt

$45

Extra requirements:

Low power consumption

Integrated Graphics

Integrated Dual-Gigabit networking

Or a Free PCI port

 

Using Old motherboard:

Requirements:

  • ·         CPU (Supports AM3 at lowered bus speeds)
  • ·         RAM (DDR2 only)
  • ·         Power Supply
  • ·         Graphics card? (temporarily use 8800GTS I guess)

 

CPU: 

Sempron 140 $31

RAM:

Kingston 2GB Value $29

Power Supply:

Vantec (As above) $45

 

TOTAL Cost:

AMD Budget AMD Ideal Intel Budget Intel Ideal Using Old Mobo
$31 + $55 + $17 + $45 $61 + $55 + $17 + $45 $47+ $59 + $17 + $45 $67 + $59 + $17 + $45 $31 + $29 + $45
$148 $178 $164 $184 $105

All prices are taken from MSY and were all in stock at the time of writing.


I would personally like to make a new machine (less the case), my experience with ad-hoc new/old part swapping is not exactly stellar.

That said, I have just been reminded of another motherboard I have left over: the M2N-SLI Deluxe; But that might be overkill in retrospect… it was designed for high performance more than anything (though it would mean I only need a power supply and a CPU to get it going.

 

*sigh.*.. i’m gonna need to think about this..

Linux ‘screen’ command

0

Just a quick note about an awesome tool I’ve discovered on my travels.

The ‘screen‘ command in a linux shell.

This neat little tool allows you to run a remote shell (via SSH in my case) and run a command so that it doesn’t die after you exit the SSH session.

Normally when you exit an SSH session while a command is being run you will kill any processes being run by that session. With screen, you basically tell it to leave that particular session in the background (running) and you can come back to it at any time and check on its progress.

I’ve found it particularly useful when I’m using Rsync to dump the files from one computer to another (as in my current predicament.

So basically your essential commands are:

localhost@user:$ screen

This makes a new screen so you are given a new shell in which to type any commands you need to run in the background.

localhost@user:$ screen -ls

This will give you a list of current screen sockets open. Note the socket number so you can get back to the screen you want.

localhost@user:$ screen -r [screen socket number]

This command will reattach/restore the screen you had running to the front so that you can check on it’s progress. If at this point you exit the shell the session will still remain and you can use the same command to restore it again.

 

Once you are finished, just type exit and it should kill the socket and drop back to the standard shell.

If for whatever reason it doesn’t drop the socket (check with screen -ls) you can either leave it (I doubt it would use much memory anyway) or use the command screen -wipe and that will destroy all sockets that have been made.

So that’s it. What a useful tool, and very easy to use.

As always with Linux, it has many more options than described here, so you can check the man pages on it (man screen) or just screen –help will give you most of what you’ll ever need.

Later.

Go to Top