Archive for the 'Hardware' Category

remapping bad spinning disk storage blocks

Monday, December 18th, 2017

Your good, old-fashioned rotating hard disk storage starts to develop bad sectors?

Dec 17 10:49:47 server kernel: end_request: I/O error, dev sdb, sector 300037184

One of the most easiest, quick and dirty ways to remap them on Linux (e.g. easier than fumbling with dd if= of=)?

Double check:

hdparm –read-sector 300037184 /dev/sdb

And if it is the block and still fails:

hdparm –write-sector 300037184 /dev/sdb –yes-i-know-…

Obviously this zeros the sector and all 512 or 4096 bytes that lived at that place are gone forever, and give way for fresh zeros from a spare, remapped reserve block.

Use only when you know what you are doing, your milage may vary.

Update: If you init a fresh Linux MD RAID, you may want to increase the min speed limit to get things going into production a bit faster:

echo 100000 > /proc/sys/dev/raid/speed_limit_min

Update2: If you are running in some error correcting RAID mode (e.g. not striped RAID 0 ;-) the Linux code will apparently re-write sectors and thus already automatically trigger a remap of those sectors:

end_request: I/O error, dev sdb, sector 301373665
ata2: EH complete
raid1:md0: read error corrected (8 sectors at 301373600 on sdb1)
raid1: sdb1: redirecting sector 301373600 to another mirror

Apple’s macOS Preview default to 100% scale

Wednesday, November 8th, 2017

You sometimes need to print documents, invoices, boarding passes, whatever? Using Apple’s macOS Preview.app and tired of having to choose: “Scale: 100%” to have an accurate printout instead of the often arbitrary default of: “Scale to Fit: 97%” or 98% (likely due to content on margins outside of your printer’s printable page size)?

defaults write com.apple.Preview PVImagePrintingScaleMode 0
defaults write com.apple.Preview PVImagePrintingAutoRotate 0

Yep. The famous Apple usability and attention to details ;-)

The different kinds of Wake-on-Lan

Sunday, September 24th, 2017

Some time ago I posted about wake on lan being hidden by a cryptic energy BIOS option. This week I was setting up a new test system and wondered what exactly the Linux ethtool:
Supports Wake-on: pumbg
letters actually meant. The man-page is help and it actually is quite simple and logical:

p Wake on PHY activity
u Wake on unicast messages
m Wake on multicast messages
b Wake on broadcast messages
a Wake on ARP
g Wake on MagicPackettm
s Enable SecureOntm password for MagicPackettm
d Disable (wake on nothing). This option clears all previous options.

Apple continues to overcharge EU customers

Wednesday, September 13th, 2017

So the new iPhone-X was just announced, let’s take a quick look on the pricing: $US 999, which does not include tax. So let’s divide this by the current $US/EUR exchange of 1.20, and adding 19% German VAT:

999 / 1.20 * 1.19 = 990,675 EUR

To be on the save side they could round this up to 999 EUR-
And what is Apple listing on their Apple Germany website?

1.149 EUR !!!

Thanks but no thanks. I do not need to be ripped of and overcharged to maximize profits and subsidize the US market.

Update: Apple is basically calculating with an currently very far off exchange rate of 1.0338 !
999/1.0338*1.19 = 1149.94…

I would rather prefer they use actual exchange rates, and instead adapt prices if necessary. As they did before in Europe, Russia, Brazil, and elsewhere, ..!

Update 2018/3 In the meantime the EUR hit 1.24, which would result in a German retail price of 958,72€ incl. the 19% local VAT, ..!

hey, ALSA’s arecord has a vu-meter

Friday, July 14th, 2017

who knew?

arecord -f cd -d 0 -vv /dev/null

;-)!

Lenovo ThinkPad T470s

Monday, July 3rd, 2017

I never owned a ThinkPad. My first PCs were built from components, and my first PC laptop was a noname. Then I got into Linux and non-x86 architectures, and as student worked on ARM, SPARC, PowerPC, MIPS. Probably in that order. Given that path of education, my second laptop probably was a G3 iBook - which I obviously run with Linux for the flawless suspend / resume at that time (2003?).

Nowadays I’m more and more disappointed by Apple’s offerings. Few ports, uncomfortable keyboards, too large trackpads, glossy displays to name a few. On the PC side there are so many cheap, but low quality options that it takes a bit or research to find your perfect fit. However, choice is good, and you could opt for a much cheaper model in case of.

One of the more outstanding, higher quality options are Lenovo ThinkPads. Purchased from IBM in 2005, they may still be the only laptops certified for use on the International Space Station.

Lenovo Germany was so kind to send me the 14″ T470s for a test.
(more…)

This annoying Sony camers w/ AVCHD files

Monday, June 12th, 2017

To process them in Linux install fuse-exfat, mount the SD with:

mount.exfat-fuse /dev/sdb1 /mnt/

and convert the properitary container to a standard one:

ffmpeg -i /mnt/PRIVATE/AVCHD/BDMV/STREAM/00001.MTS -codec copy myfile.mp4

Changing the Ethernet Mac address

Wednesday, June 7th, 2017

For fun or for profit:

sudo ifconfig en0 ether eb:ec:4a:9a:1e:b8

Of course choose your own truly random hex numbers ;-)

Dell XPS 13 9360 Developer Edition

Monday, April 10th, 2017

Last year Dell was so kind to send me the Intel Skylake based 15″ XPS 9550. As expected Dell recently refreshed the XPS series with the Kaby Lake generation of Intel’s platforms, and I could take a look on the refreshed silicon in the 13″ form factor.

The 13″ edition comes with the same light and sturdy carbon fibre, with a gentle silicone surface. As mentioned in last years post I like it for the thermal and electrical isolation. The same infinity edge display still optimises the size of the case, so that the 13″ display is effectively packed into the size of a conventional 12″ laptop. A really welcome light and compact travel companion.
(more…)

Latest Mac’s build in hardware test

Wednesday, March 1st, 2017

Historically there was an Apple hardware test that you could boot to check if your Mac’s hardware is all good.

It came to a surprise though, that with newer Macs simply holding the ‘d’ during power on it runs some simple hardware diagnostic, too.

One should probably more often read Apple’s support pages, ..