2.8.15

Foto návody k prežitiu od Armytraining

Po úspešnom absolvovaní letného kurzu prežitia a absolútnej spokojnosti s výcvikom, som dnes ráno chcel pozrieť aký ďalší kurz absolvovať u Patrika a jeho teamu.
Hlavná stránka www.armytraining.sk sa mi zdala byť ako keby zmenená oproti tomu, kedy som ju naposledy navštívil.
Scrollol som dole a bol tam formulár, korý som ešte nevidel, tak som sa začítal, čo to je.

Foto návod prihlásenie

Počas kurzu Patrik a Peter fotili veci a činnosti. Aj som sa ich spýtal, keď som popri nich prechádzal, že robíte manuál? Patrik hneď na to odpoveď, bez dlhého rozmýšlania, že áno.
Teraz už viem prečo fotili veci počas prestávok na výcviku.

Prihlásenie k odberu je zadarmo, tak som sa prihlásil.
Po prihlásení mi hneď prišiel prvý návod, Pečenie chutného chlebíka v prírode nemusí byť trauma na celý život...


Foto návod dorazil do email schránky
Podľa mňa super marketingový ťah, ale i super užitočné, ak nie život zachraňujúce info.

31.7.15

Skúšobne som si zaplatil vladozlatos.com VIP členstvo

Vladov blog už sledujem pár rokov a absolvoval som s ním osobnú konzultáciu tovaroznalectvo v Terne, Aupark, Bratislava. Veľa informácií má na blogu, čo je veľmi dobré a ďakujem za ne.

Infá na blogu sú jedna super vec, ale osobné stretnutie má predsa len pridanú hodnotu a z druhého uhľa pohľadu, ak naďalej chcem čítať jeho bádania a výskumy, tak ho predsa finančne musím podporiť. Internet a elektrinu tiež nemá zadarmo. Nikdy nezabudnem, keď sme si prvýkrát podali ruky :) Hlavný vchod do Auparku pri informáciach. O pár centimetrov nižší než ja a vôbec nevysekaný svalmi ako kulturista z Muscle&Fitness. Podáme si ruky a nečakaný pocit. Mal som pocit, že som ruku dal do zveráka, chalan mal proste silu! Po tejto situácii bol hneď môj úsudok, že to čo na blogu píše bude mať pointu.

Asi toľko o spoznaní Vlada Zlatoša. Ako som spomínal, považuje za dôležité "sponzoring" jeho písania s kúpou jeho služieb či produktov.

Včera som čítal, že na webe ponúka VIP členstvo. Po prečítaní moja zaujatosť neklesla, skôr som ostal ešte zvedavší, čo za materiály to môžu byť? Veľa som neváhal a z peňaženky vybral platobnú kartu a začal proces objednávania.

Mesačné členstvo VIP = = 19 eur/mesiac (úspora 11 eur/mesiac = 132 eur/rok)
Po úspešnej objednávke som sa preklikol do môjho konta, čo som si ja za vec kúpil?
Čakal ma tam výber tém, o ktorých chcem byť informovaný.

VIP Výber záujmových tém

Vyklikal som pre mňa zaujímave témy, skoro všetky a následne dal uložiť. Dokumenty sa v mojom konte nezobrazili hneď. Vrátil som sa späť na promo článok a našiel vysvetlenie. Prvé dokumenty vám prídu v nasledovný deň a dostanete o tom emailovú notifikáciu.

No a dnes mi spomínaný notifikačný email aj došiel kým som spal :D

Nová položka na stiahnutie vo Vašej predplatenej VIP sekcii/sekciách: Databáza recenzií kníh, Databáza potravín, Databáza dôležitých otázok
Prihlásil som sa na webe www.vladozlatos.com a potom klikol na odkaz v maily, nechcelo sa mi cez web preklikávať :) Už mi neostáva iné len stiahnúť si materiály a zahĺbiť sa do myšlienok, o ktoré sa majú podeliť.

Sekcia VIP na stiahnutie

Toľko z dojmov a myšlienok o VIP službe Vlada. Idem si vychutnať a prečítať si dostupné materiály.

PS: Mega hneď ako prvé recenzia knihy Reštart, Fried je jeden z mojich obľubených.

PPS: Ty si ešte zvedavý ako dokument vyzerá? Tak tu máš náhľad:



Môj prvý repasovaný notebook

Mojou srdcovkou vždy boli a sú ThinkPad notebooky. Preto koncom roku 2013 som už ďalej nečakal a z eshopu lacne-pc.sk za 200 Eur kúpil svoj prvý repasovaný notebook, T60-ku ešte z dielne IBM a nie Lenovo.
Dovtedy som nemal skúsenosť s repasovanou technikou, ale v eshope uvádzali 2-ročnú záruku, tak som neváhal. Netušil som v akom stave bude, predsa je to použitý notebook a hlavne dokedy mi bude slúžiť. Chvála bohu som sa v ThinkPade T60 nesklamal. Jediné, čo mi v ten čas vadilo boli jeho výkonnostné parametre, ale tak predsa je to starší model a nie kvôli jeho výkonu som ho kupoval.
Notebook momentákne slúži ako server pre rôzne testovania, monitoring (Zabbix), uložisko dát a vzdialený prístup k iným serverom. Beží na ňom Arch Linux aktualizovaný vtedy, keď ma napadne.

Repas či nový?

Ja som neskutočne spokojný s T60 a pravdupoviedac ako pozerám znova ponuku eshopu a ich repasované notebooky, tak mi v myšlienkach nedá pokoj X201, ktorá je rozmerovo menšia, čo by sa mi k cestovaniu a vzdialenej práci (remote work) hodilo. Má v sebe Intel Core i5 procesor, ktorá by mi v pohode stačila a RAM + SSD disk si zas viem dokúpiť.
Pre porovnanie som si pozrel koľko stojí nová X240 a najlacnejšia varianta na lenovoonline.sk je za 853 Eur, ale ten nový dizajn sa mi už moc nepáči. Dalo by sa polemizovať, ale pre mňa osobne je efektívnejšia a ekonomicky výhodnejšia repasovaná alternatíva. Parametre takmer rovnaké.

Zopár technických údajov na záver

mike@lenovo-t60:~$ lspci
00:00.0 Host bridge: Intel Corporation Mobile 945GM/PM/GMS, 943/940GML and 945GT Express Memory Controller Hub (rev 03)
00:02.0 VGA compatible controller: Intel Corporation Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller (rev 03)
00:02.1 Display controller: Intel Corporation Mobile 945GM/GMS/GME, 943/940GML Express Integrated Graphics Controller (rev 03)
00:1b.0 Audio device: Intel Corporation NM10/ICH7 Family High Definition Audio Controller (rev 02)
00:1c.0 PCI bridge: Intel Corporation NM10/ICH7 Family PCI Express Port 1 (rev 02)
00:1c.1 PCI bridge: Intel Corporation NM10/ICH7 Family PCI Express Port 2 (rev 02)
00:1c.2 PCI bridge: Intel Corporation NM10/ICH7 Family PCI Express Port 3 (rev 02)
00:1c.3 PCI bridge: Intel Corporation NM10/ICH7 Family PCI Express Port 4 (rev 02)
00:1d.0 USB controller: Intel Corporation NM10/ICH7 Family USB UHCI Controller #1 (rev 02)
00:1d.1 USB controller: Intel Corporation NM10/ICH7 Family USB UHCI Controller #2 (rev 02)
00:1d.2 USB controller: Intel Corporation NM10/ICH7 Family USB UHCI Controller #3 (rev 02)
00:1d.3 USB controller: Intel Corporation NM10/ICH7 Family USB UHCI Controller #4 (rev 02)
00:1d.7 USB controller: Intel Corporation NM10/ICH7 Family USB2 EHCI Controller (rev 02)
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev e2)
00:1f.0 ISA bridge: Intel Corporation 82801GBM (ICH7-M) LPC Interface Bridge (rev 02)
00:1f.1 IDE interface: Intel Corporation 82801G (ICH7 Family) IDE Controller (rev 02)
00:1f.2 SATA controller: Intel Corporation 82801GBM/GHM (ICH7-M Family) SATA Controller [AHCI mode] (rev 02)
00:1f.3 SMBus: Intel Corporation NM10/ICH7 Family SMBus Controller (rev 02)
02:00.0 Ethernet controller: Intel Corporation 82573L Gigabit Ethernet Controller
03:00.0 Network controller: Intel Corporation PRO/Wireless 3945ABG [Golan] Network Connection (rev 02)
15:00.0 CardBus bridge: Texas Instruments PCI1510 PC card Cardbus Controller


mike@lenovo-t60:~$ lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 002: ID 1199:6804 Sierra Wireless, Inc. MC8755 Device
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub


mike@lenovo-t60:~$ lscpu
Architecture: i686
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPU(s): 2
On-line CPU(s) list: 0,1
Thread(s) per core: 1
Core(s) per socket: 2
Socket(s): 1
Vendor ID: GenuineIntel
CPU family: 6
Model: 15
Model name: Intel(R) Core(TM)2 CPU T5500 @ 1.66GHz
Stepping: 6
CPU MHz: 1000.000
CPU max MHz: 1667.0000
CPU min MHz: 1000.0000
BogoMIPS: 3326.51
L1d cache: 32K
L1i cache: 32K
L2 cache: 2048K
Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe lm constant_tsc arch_perfmon pebs bts aperfmperf pni dtes64 monitor ds_cpl est tm2 ssse3 cx16 xtpr pdcm lahf_lm dtherm


mike@lenovo-t60:~$ sudo smartctl --info /dev/sda
smartctl 6.4 2015-06-04 r4109 [i686-linux-4.0.3-1-ARCH] (local build)
Copyright (C) 2002-15, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF INFORMATION SECTION ===
Device Model: HITACHI HTS725016A9A364
Serial Number: 100411PCKB04VNGJY4
LU WWN Device Id: 5 000cca 5b9c7b362
Firmware Version: PCBZC70F
User Capacity: 160,041,885,696 bytes [160 GB]
Sector Size: 512 bytes logical/physical
Rotation Rate: 7200 rpm
Form Factor: 2.5 inches
Device is: Not in smartctl database [for details use: -P showall]
ATA Version is: ATA8-ACS T13/1699-D revision 6
SATA Version is: SATA 2.6, 3.0 Gb/s (current: 1.5 Gb/s)
Local Time is: Thu Jul 9 12:01:30 2015 CEST
SMART support is: Available - device has SMART capability.
SMART support is: Enabled


mike@lenovo-t60:~$ df -h
Filesystem Size Used Avail Use% Mounted on
dev 1004M 0 1004M 0% /dev
run 1006M 556K 1005M 1% /run
/dev/sda2 15G 6.6G 7.4G 48% /
tmpfs 1006M 0 1006M 0% /dev/shm
tmpfs 1006M 0 1006M 0% /sys/fs/cgroup
tmpfs 1006M 19M 987M 2% /tmp
/dev/sda4 128G 100G 22G 83% /home
/dev/sda1 485M 38M 422M 9% /boot
tmpfs 202M 0 202M 0% /run/user/1000


mike@lenovo-t60:~$ lshw
lenovo-t60
description: Notebook
product: 1951VN1
vendor: LENOVO
version: ThinkPad T60
serial: L3NCM28
width: 32 bits
capabilities: smbios-2.4 dmi-2.4 smp-1.4 smp
configuration: administrator_password=disabled boot=normal chassis=notebook cpus=2 family=ThinkPad T60 frontpanel_password=unknown keyboard_password=disabled power-on_password=disabled
*-core
description: Motherboard
product: 1951VN1
vendor: LENOVO
physical id: 0
version: Not Available
serial: VF0S177M12X
*-firmware
description: BIOS
vendor: LENOVO
physical id: 0
version: 79ETE3WW (2.23 )
date: 09/12/2008
size: 144KiB
capacity: 1984KiB
capabilities: pci pcmcia pnp upgrade shadowing escd cdboot bootselect socketedrom edd acpi usb biosbootspecification
*-cpu:0
description: CPU
product: Intel(R) Core(TM)2 CPU T5500 @ 1.66GHz
vendor: Intel Corp.
physical id: 6
bus info: cpu@0
version: 6.15.6
serial: 0000-06F6-0000-0000-0000-0000
slot: None
size: 1333MHz
capacity: 1667MHz
width: 64 bits
clock: 167MHz
capabilities: boot fpu fpu_exception wp vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe x86-64 constant_tsc arch_perfmon pebs bts aperfmperf pni dtes64 monitor ds_cpl est tm2 ssse3 cx16 xtpr pdcm lahf_lm dtherm cpufreq
configuration: id=1
*-cache:0
description: L1 cache
physical id: a
slot: Internal L1 Cache
size: 64KiB
capacity: 64KiB
capabilities: synchronous internal write-back instruction
*-cache:1
description: L2 cache
physical id: c
slot: Internal L2 Cache
size: 2MiB
capacity: 2MiB
capabilities: burst internal write-back unified
*-logicalcpu:0
description: Logical CPU
physical id: 1.1
width: 64 bits
capabilities: logical
*-logicalcpu:1
description: Logical CPU
physical id: 1.2
width: 64 bits
capabilities: logical
*-cache
description: L1 cache
physical id: b
slot: Internal L1 Cache
size: 64KiB
capacity: 64KiB
capabilities: synchronous internal write-back data
*-memory
description: System Memory
physical id: 29
slot: System board or motherboard
size: 2GiB
capacity: 2GiB
*-bank:0
description: SODIMM DDR2 Synchronous
physical id: 0
slot: DIMM 1
size: 1GiB
width: 64 bits
*-bank:1
description: SODIMM DDR2 Synchronous
physical id: 1
slot: DIMM 2
size: 1GiB
width: 64 bits
*-cpu:1
physical id: 1
bus info: cpu@1
version: 6.15.6
serial: 0000-06F6-0000-0000-0000-0000
size: 1667MHz
capacity: 1667MHz
capabilities: ht cpufreq
configuration: id=1
*-logicalcpu:0
description: Logical CPU
physical id: 1.1
capabilities: logical
*-logicalcpu:1
description: Logical CPU
physical id: 1.2
capabilities: logical
*-pci
description: Host bridge
product: Mobile 945GM/PM/GMS, 943/940GML and 945GT Express Memory Controller Hub
vendor: Intel Corporation
physical id: 100
bus info: pci@0000:00:00.0
version: 03
width: 32 bits
clock: 33MHz
configuration: driver=agpgart-intel
resources: irq:0
*-display:0
description: VGA compatible controller
product: Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller
vendor: Intel Corporation
physical id: 2
bus info: pci@0000:00:02.0
version: 03
width: 32 bits
clock: 33MHz
capabilities: msi pm vga_controller bus_master cap_list rom
configuration: driver=i915 latency=0
resources: irq:16 memory:ee100000-ee17ffff ioport:1800(size=8) memory:d0000000-dfffffff memory:ee200000-ee23ffff
*-display:1 UNCLAIMED
description: Display controller
product: Mobile 945GM/GMS/GME, 943/940GML Express Integrated Graphics Controller
vendor: Intel Corporation
physical id: 2.1
bus info: pci@0000:00:02.1
version: 03
width: 32 bits
clock: 33MHz
capabilities: pm cap_list
configuration: latency=0
resources: memory:ee180000-ee1fffff
*-multimedia
description: Audio device
product: NM10/ICH7 Family High Definition Audio Controller
vendor: Intel Corporation
physical id: 1b
bus info: pci@0000:00:1b.0
version: 02
width: 64 bits
clock: 33MHz
capabilities: pm msi pciexpress bus_master cap_list
configuration: driver=snd_hda_intel latency=0
resources: irq:31 memory:ee240000-ee243fff
*-pci:0
description: PCI bridge
product: NM10/ICH7 Family PCI Express Port 1
vendor: Intel Corporation
physical id: 1c
bus info: pci@0000:00:1c.0
version: 02
width: 32 bits
clock: 33MHz
capabilities: pci pciexpress msi pm normal_decode bus_master cap_list
configuration: driver=pcieport
resources: irq:24 ioport:2000(size=4096) memory:ee000000-ee0fffff ioport:80000000(size=2097152)
*-network
description: Ethernet interface
product: 82573L Gigabit Ethernet Controller
vendor: Intel Corporation
physical id: 0
bus info: pci@0000:02:00.0
logical name: ens2
version: 00
serial: 00:1a:6b:6c:08:e0
size: 1Gbit/s
capacity: 1Gbit/s
width: 32 bits
clock: 33MHz
capabilities: pm msi pciexpress bus_master cap_list ethernet physical tp 10bt 10bt-fd 100bt 100bt-fd 1000bt-fd autonegotiation
configuration: autonegotiation=on broadcast=yes driver=e1000e driverversion=2.3.2-k duplex=full firmware=0.5-1 ip=192.168.100.103 latency=0 link=yes multicast=yes port=twisted pair speed=1Gbit/s
resources: irq:29 memory:ee000000-ee01ffff ioport:2000(size=32)
*-pci:1
description: PCI bridge
product: NM10/ICH7 Family PCI Express Port 2
vendor: Intel Corporation
physical id: 1c.1
bus info: pci@0000:00:1c.1
version: 02
width: 32 bits
clock: 33MHz
capabilities: pci pciexpress msi pm normal_decode bus_master cap_list
configuration: driver=pcieport
resources: irq:25 ioport:3000(size=8192) memory:ec000000-edffffff ioport:e4000000(size=1048576)
*-network DISABLED
description: Wireless interface
product: PRO/Wireless 3945ABG [Golan] Network Connection
vendor: Intel Corporation
physical id: 0
bus info: pci@0000:03:00.0
logical name: wls3
version: 02
serial: 00:1b:77:70:24:55
width: 32 bits
clock: 33MHz
capabilities: pm msi pciexpress bus_master cap_list ethernet physical wireless
configuration: broadcast=yes driver=iwl3945 driverversion=4.0.3-1-ARCH firmware=N/A latency=0 link=no multicast=yes wireless=IEEE 802.11abg
resources: irq:30 memory:edf00000-edf00fff
*-pci:2
description: PCI bridge
product: NM10/ICH7 Family PCI Express Port 3
vendor: Intel Corporation
physical id: 1c.2
bus info: pci@0000:00:1c.2
version: 02
width: 32 bits
clock: 33MHz
capabilities: pci pciexpress msi pm normal_decode bus_master cap_list
configuration: driver=pcieport
resources: irq:26 ioport:5000(size=8192) memory:e8000000-e9ffffff ioport:e4100000(size=1048576)
*-pci:3
description: PCI bridge
product: NM10/ICH7 Family PCI Express Port 4
vendor: Intel Corporation
physical id: 1c.3
bus info: pci@0000:00:1c.3
version: 02
width: 32 bits
clock: 33MHz
capabilities: pci pciexpress msi pm normal_decode bus_master cap_list
configuration: driver=pcieport
resources: irq:27 ioport:7000(size=8192) memory:ea000000-ebffffff ioport:e4200000(size=1048576)
*-usb:0
description: USB controller
product: NM10/ICH7 Family USB UHCI Controller #1
vendor: Intel Corporation
physical id: 1d
bus info: pci@0000:00:1d.0
version: 02
width: 32 bits
clock: 33MHz
capabilities: uhci bus_master
configuration: driver=uhci_hcd latency=0
resources: irq:16 ioport:1820(size=32)
*-usbhost
product: UHCI Host Controller
vendor: Linux 4.0.3-1-ARCH uhci_hcd
physical id: 1
bus info: usb@2
logical name: usb2
version: 4.00
capabilities: usb-1.10
configuration: driver=hub slots=2 speed=12Mbit/s
*-usb:1
description: USB controller
product: NM10/ICH7 Family USB UHCI Controller #2
vendor: Intel Corporation
physical id: 1d.1
bus info: pci@0000:00:1d.1
version: 02
width: 32 bits
clock: 33MHz
capabilities: uhci bus_master
configuration: driver=uhci_hcd latency=0
resources: irq:17 ioport:1840(size=32)
*-usbhost
product: UHCI Host Controller
vendor: Linux 4.0.3-1-ARCH uhci_hcd
physical id: 1
bus info: usb@3
logical name: usb3
version: 4.00
capabilities: usb-1.10
configuration: driver=hub slots=2 speed=12Mbit/s
*-usb
description: Generic USB device
product: Mini Card
vendor: Sierra Wireless, Incorporated
physical id: 1
bus info: usb@3:1
version: 0.01
capabilities: usb-1.10
configuration: driver=sierra speed=12Mbit/s
*-usb:2
description: USB controller
product: NM10/ICH7 Family USB UHCI Controller #3
vendor: Intel Corporation
physical id: 1d.2
bus info: pci@0000:00:1d.2
version: 02
width: 32 bits
clock: 33MHz
capabilities: uhci bus_master
configuration: driver=uhci_hcd latency=0
resources: irq:18 ioport:1860(size=32)
*-usbhost
product: UHCI Host Controller
vendor: Linux 4.0.3-1-ARCH uhci_hcd
physical id: 1
bus info: usb@4
logical name: usb4
version: 4.00
capabilities: usb-1.10
configuration: driver=hub slots=2 speed=12Mbit/s
*-usb:3
description: USB controller
product: NM10/ICH7 Family USB UHCI Controller #4
vendor: Intel Corporation
physical id: 1d.3
bus info: pci@0000:00:1d.3
version: 02
width: 32 bits
clock: 33MHz
capabilities: uhci bus_master
configuration: driver=uhci_hcd latency=0
resources: irq:19 ioport:1880(size=32)
*-usbhost
product: UHCI Host Controller
vendor: Linux 4.0.3-1-ARCH uhci_hcd
physical id: 1
bus info: usb@5
logical name: usb5
version: 4.00
capabilities: usb-1.10
configuration: driver=hub slots=2 speed=12Mbit/s
*-usb:4
description: USB controller
product: NM10/ICH7 Family USB2 EHCI Controller
vendor: Intel Corporation
physical id: 1d.7
bus info: pci@0000:00:1d.7
version: 02
width: 32 bits
clock: 33MHz
capabilities: pm debug ehci bus_master cap_list
configuration: driver=ehci-pci latency=0
resources: irq:19 memory:ee444000-ee4443ff
*-usbhost
product: EHCI Host Controller
vendor: Linux 4.0.3-1-ARCH ehci_hcd
physical id: 1
bus info: usb@1
logical name: usb1
version: 4.00
capabilities: usb-2.00
configuration: driver=hub slots=8 speed=480Mbit/s
*-pci:4
description: PCI bridge
product: 82801 Mobile PCI Bridge
vendor: Intel Corporation
physical id: 1e
bus info: pci@0000:00:1e.0
version: e2
width: 32 bits
clock: 33MHz
capabilities: pci subtractive_decode bus_master cap_list
resources: ioport:9000(size=16384) memory:e4300000-e7ffffff ioport:e0000000(size=67108864)
*-pcmcia
description: CardBus bridge
product: PCI1510 PC card Cardbus Controller
vendor: Texas Instruments
physical id: 0
bus info: pci@0000:15:00.0
version: 00
width: 32 bits
clock: 33MHz
capabilities: pcmcia bus_master cap_list
configuration: driver=yenta_cardbus latency=176 maxlatency=5 mingnt=192
resources: irq:16 memory:e4300000-e4300fff ioport:9000(size=256) ioport:9400(size=256) memory:e0000000-e3ffffff memory:84000000-87ffffff
*-isa
description: ISA bridge
product: 82801GBM (ICH7-M) LPC Interface Bridge
vendor: Intel Corporation
physical id: 1f
bus info: pci@0000:00:1f.0
version: 02
width: 32 bits
clock: 33MHz
capabilities: isa bus_master cap_list
configuration: driver=lpc_ich latency=0
resources: irq:0
*-ide
description: IDE interface
product: 82801G (ICH7 Family) IDE Controller
vendor: Intel Corporation
physical id: 1f.1
bus info: pci@0000:00:1f.1
version: 02
width: 32 bits
clock: 33MHz
capabilities: ide bus_master
configuration: driver=ata_piix latency=0
resources: irq:16 ioport:1f0(size=8) ioport:3f6 ioport:170(size=8) ioport:376 ioport:1810(size=16)
*-storage
description: SATA controller
product: 82801GBM/GHM (ICH7-M Family) SATA Controller [AHCI mode]
vendor: Intel Corporation
physical id: 1f.2
bus info: pci@0000:00:1f.2
version: 02
width: 32 bits
clock: 66MHz
capabilities: storage msi pm ahci_1.0 bus_master cap_list
configuration: driver=ahci latency=0
resources: irq:28 ioport:18d0(size=8) ioport:18c4(size=4) ioport:18c8(size=8) ioport:18c0(size=4) ioport:18b0(size=16) memory:ee444400-ee4447ff
*-serial
description: SMBus
product: NM10/ICH7 Family SMBus Controller
vendor: Intel Corporation
physical id: 1f.3
bus info: pci@0000:00:1f.3
version: 02
width: 32 bits
clock: 33MHz
configuration: driver=i801_smbus latency=0
resources: irq:23 ioport:18e0(size=32)




27.4.14

Composite (RCA) TV-out to SCART from Raspberry

Today I finally made time to try Pi's composite TV out [AV button on TV remote control :].



I had to edit my NOOBS /boot/config.txt to disable HDMI and enable Standard Definition Video.
# for more options see http://elinux.org/RPi_config.txt

# uncomment if you get no picture on HDMI for a default "safe" mode
#hdmi_safe=1

# uncomment to force a console size. By default it will be display's size minus
# overscan.
#framebuffer_width=1280
#framebuffer_height=720

#hdmi_force_hotplug=1 # uncomment to enable hdmi
#config_hdmi_boost=4
overscan_left=24
overscan_right=24
overscan_top=16
overscan_bottom=16
#disable_overscan=0

# overclock
arm_freq=900
sdram_freq=450
core_freq=350
force_turbo=1

################################################################################
##  Standard Definition Video Settings
################################################################################

## sdtv_mode
##     defines the TV standard for composite output
##
##     Value    Description
##     -------------------------------------------------------------------------
##     0        Normal NTSC (Default)
##     1        Japanese version of NTSC - no pedestal
##     2        Normal PAL
##     3        Brazilian version of PAL - 525/60 rather than 625/50, different
##              subcarrier
##
sdtv_mode=2

## sdtv_aspect
##     defines the aspect ratio for composite output
##
##     Value    Description
##     -------------------------------------------------------------------------
##     1        4:3 (Default)
##     2        14:9
##     3        16:9
##
sdtv_aspect=1

## sdtv_disable_colourburst
##     Disables colour burst on composite output. The picture will be
##     monochrome, but possibly sharper
##
##     Value    Description
##     -------------------------------------------------------------------------
##     0        Colour burst is enabled (Default)
##     1        Colour burst is disabled
##
#sdtv_disable_colourburst=1
After rebooting (sudo shutdown -r now) I had no screen change on the TV :( I checked and the output was well set.
pi@raspi ~ $ tvservice -s
state 0x80002 [PAL 4:3], 720x576 @ 50.00Hz, interlaced
Without solution I read a bunch of thread at http://www.raspberrypi.org/forums/viewforum.php?f=28, but no solution. I signed up and made photos for the bug report and by viewing a saw that the SCART is switched to OUTPUT and by switching to INPUT the screen on TV changed.

UPDATE 31.7.2015 - Photos of the used cable and SCART https://goo.gl/photos/dSwhfFQjd3yf3Mrk7https://goo.gl/photos/171jGm9EGKCBAgq98


9.4.14

Compiling w_scan

I bought a DVB-T USB and needed w_scan to scan channels.
$ lsusb
Bus 001 Device 005: ID 048d:9006 Integrated Technology Express, Inc.
$ modprobe dvb_usb_it913x
Source code is at http://wirbel.htpc-forum.de/w_scan/index2.html
$ cd /tmp
$ wget http://wirbel.htpc-forum.de/w_scan/w_scan-20140118.tar.bz2
$ tar jxvf w_scan-20140118.tar.bz2
$ cd w_scan-20140118
Solving "ERROR: w_scan requires linux DVB API v5.3 or higher":
$ CFLAGS="-I /usr/src/linux-headers-3.3.4-030304/include/" ./configure
$ make
$ sudo cp w_scan /usr/bin

$ w_scan -c SK
w_scan version 20140118 (compiled for DVB API 5.5)
using settings for SLOVAKIA
DVB aerial
DVB-T Europe
scan type TERRESTRIAL, channellist 4
output format vdr-2.0
WARNING: could not guess your codepage. Falling back to 'UTF-8'
output charset 'UTF-8', use -C  to override
Info: using DVB adapter auto detection.
        /dev/dvb/adapter0/frontend0 -> TERRESTRIAL "ITE 9135(9006) Generic_1": good :-)
Using TERRESTRIAL frontend (adapter /dev/dvb/adapter0/frontend0)
-_-_-_-_ Getting frontend capabilities-_-_-_-_
Using DVB API 5.5
frontend 'ITE 9135(9006) Generic_1' supports
INVERSION_AUTO
QAM_AUTO
TRANSMISSION_MODE_AUTO
GUARD_INTERVAL_AUTO
HIERARCHY_AUTO
FEC_AUTO
FREQ (51.00MHz ... 1680.00MHz)
-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_
Scanning 7MHz frequencies...
177500: (time: 00:01)
184500: (time: 00:05)
191500: (time: 00:09)
198500: (time: 00:13)
205500: (time: 00:19)
212500: (time: 00:26)
219500: (time: 00:31)
226500: (time: 00:35)
Scanning 8MHz frequencies...

1.3.14

Switched from Console.app to multitail

With Console.app I had the problem that when I switched to output /var/log/apache2/error_log I didn't see
/var/log/system.log and yesterday I read http://kkovacs.eu/cool-but-obscure-unix-tools and found multitail so I played with it.

I'm currently running the following setup on OSX Mountain Lion

mike@mikembp:~$ cat bin/multitail-log.sh
#!/bin/bash

multitail -s 2 /tmp/lsof-net.log \
    /var/log/apache2/error_log \
    /var/log/system.log -I /var/log/wifi.log -I /var/log/mail.log \
    /var/log/mysql.log

I had to make a crontab to get /tmp/lsof-net.log file, because multitail -R 2 -l "lsof lsof -RPi4 +c15" was crashing with "Operation not permitted". I think the problem is that lsofon Mac is in /usr/sbin. Crons minimal execution is every minute so I had to call the desired command 29 times with 2 second sleep.

mike@mikembp:~$ cat bin/cron-netlog.sh
#!/bin/bash

# crontab -e
# * * * * * /Users/mike/bin/cron-netlog.sh

LOGFILE=/tmp/lsof-net.log

for (( i=1; i <= 29; i++ ))
do
    /usr/sbin/lsof -RPi4 +c15 | grep -v -e rtorrent -e Mail -e Last | awk '{print $1,$2,$3,$4,$9,$10}' | column -t >> $LOGFILE
    sleep 2
done

mike@mikembp:~$ cat .crontab
# ~/.crontab
#
# Run:
# crontab ~/.crontab

MAILTO=user@example.com

* * * * * ~/bin/cron-netlog.sh

mike@mikembp:~$ crontab .crontab

26.2.14

Choosing the fastest DNS by benchmarking

Today I used Google's public DNS servers with a WiFi hotspot, never used it so I read about it and came acrooss https://code.google.com/p/namebench/
I tried it with the ISPs DNS servers and got the following result (suggestions for improving) http://namebench.appspot.com/id/71560011 for 100 queries and http://namebench.appspot.com/id/73540001 for 200 queries.

22.2.14

Kali Linux install fail

I tried to install Kali in VBox with 4GB and for the second time on 8GB which wasn't enough, according to /var/log/syslog

So I checked the install docs and there was the answer how much should I use. So it's good to go throught the install docs before installing at http://docs.kali.org/installation/kali-linux-hard-disk-install and check the requirements.

After installing the system takes 9.7GB

21.2.14

Filesystem Hierarchy Standard

I just came across of Filesystem Hierarchy Standard (FHS). It is a standard that consists of a set of requirements and guidelines for file and directory placement under UNIX-like operating systems.
The guidelines are intended to support interoperability of applications, system administration tools, development tools, and scripts as well as greater uniformity of documentation for these systems.

The following directories, or symbolic links to directories, are required in /.


Directory Description
/bin Essential command binaries
/boot Static files of the boot loader
/dev Device files
/etc Host-specific system configuration
/lib Essential shared libraries and kernel modules
/media Mount point for removeable media
/mnt Mount point for mounting a filesystem temporarily
/opt Add-on application software packages
/sbin Essential system binaries
/srv Data for services provided by this system
/tmp Temporary files
/usr Secondary hierarchy
/var Variable data

Official site http://www.pathname.com/fhs/

REPLACE instead of SELECT and then INSERT or UPDATE

It's nice that MySQL has the replace query so instead SELECTing to check if the data exists in the DB and than INSERTing or UPDATEing I just need to write one query.

So instead this:
$q = "SELECT id FROM table WHERE name = 'value' AND name2 = 'value2' LIMIT 1;";
$id = $database->get_one($q);
if ($id > 0) {
    $q = "UPDATE table SET name = 'value', name2 = 'value2' WHERE id = $id LIMIT 1;";
}
else {
    $q = "INSERT INTO table (name, name2) VALUES ('value', 'value2');";
}
$database->query($q);

I just query once
$q = "REPLACE INTO table (name, name2) VALUES ('value', 'value2');";
$database->query($q);


More info at
http://blogs.coldbuffer.com/inserting-or-updating-records-using-mysql-replace
https://dev.mysql.com/doc/refman/5.0/en/replace.html

Great description and examples of Linux commands

Found a great description of some Linux commands at http://www.linfo.org/command_index.html which I definitely recommend for newbies. Some of my favourits:
mike@jarvis:/media/sdb1/www$ find . -type d -exec sudo chmod 0775 {} \;
mike@jarvis:/media/sdb1/www$ find . -type f -exec sudo chmod 0664 {} \;

mike@mikembp:~$ tail -f /var/log/apache2/error_log
PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/lib/php/extensions/no-debug-non-zts-20090626/imagick.so' - dlopen(/usr/lib/php/extensions/no-debug-non-zts-20090626/imagick.so, 9): Library not loaded: /opt/local/lib/libpng15.15.dylib\n  Referenced from: /usr/lib/php/extensions/no-debug-non-zts-20090626/imagick.so\n  Reason: image not found in Unknown on line 0
[Fri Feb 21 05:03:12 2014] [notice] Digest: generating secret for digest authentication ...
[Fri Feb 21 05:03:12 2014] [notice] Digest: done
[Fri Feb 21 05:03:12 2014] [info] Init: Seeding PRNG with 144 bytes of entropy
[Fri Feb 21 05:03:12 2014] [info] Init: Generating temporary RSA private keys (512/1024 bits)
[Fri Feb 21 05:03:13 2014] [info] Init: Generating temporary DH parameters (512/1024 bits)
[Fri Feb 21 05:03:13 2014] [info] Init: Initializing (virtual) servers for SSL
[Fri Feb 21 05:03:13 2014] [info] mod_ssl/2.2.24 compiled against Server: Apache/2.2.24, Library: OpenSSL/0.9.8y
[Fri Feb 21 05:03:13 2014] [notice] Apache/2.2.24 (Unix) DAV/2 PHP/5.3.26 mod_ssl/2.2.24 OpenSSL/0.9.8y configured -- resuming normal operations
[Fri Feb 21 05:03:13 2014] [info] Server built: Jul  7 2013 18:05:17

mike@mikembp:~$ id
uid=501(mike) gid=20(staff) groups=20(staff),401(com.apple.access_screensharing),503(access_bpf),0(wheel),12(everyone),33(_appstore),61(localaccounts),79(_appserverusr),80(admin),81(_appserveradm),98(_lpadmin),100(_lpoperator),204(_developer)

mike@mikembp:~$ du -sh /Users/mike/Movies/movie/
 29G    /Users/mike/Movies/movie/

mike@mikembp:~$ ps -ef |grep -i little
    0   112     1   0  5:03AM ??         0:20.64 /Library/Little Snitch/Little Snitch Daemon.bundle/Contents/MacOS/Little Snitch Daemon
  501   675   662   0  5:03AM ??         2:22.88 /Library/Little Snitch/Little Snitch Agent.app/Contents/MacOS/Little Snitch Agent
  501   686   662   0  5:03AM ??         0:54.07 /Library/Little Snitch/Little Snitch Network Monitor.app/Contents/MacOS/Little Snitch Network Monitor -psn_0_49164
  501 17552   782   0  7:59AM ttys004    0:00.00 grep --colour=auto --exclude-dir=.svn -i little

mike@mikembp:~/Sites$ sudo chown -R mike:_www *

mike@mikembp:~$ rsync -zva --progress Dropbox/bookmarks-firefox.json mike@jarvis:.
building file list ...
1 file to consider
bookmarks-firefox.json
      156268 100%   14.72MB/s    0:00:00 (xfer#1, to-check=0/1)

sent 36818 bytes  received 42 bytes  4336.47 bytes/sec
total size is 156268  speedup is 4.24

Learning about inodes

Yesterday I watched again Antitrust, but now in HD 720p to better see the commands he used :) He was playing with inodes to restore removed data and I became curious, because I heard and saw inodes, but never knew what are they.
For me useful info was at http://www.linfo.org/inode.html and http://www.cyberciti.biz/tips/understanding-unixlinux-filesystem-inodes.html I didn't know about the command stat:
mike@mikembp:~$ stat -x /etc/php.ini
  File: "/etc/php.ini"
  Size: 70183        FileType: Regular File
  Mode: (0644/-rw-r--r--)         Uid: (    0/    root)  Gid: (    0/   wheel)
Device: 1,2   Inode: 26362462    Links: 1
Access: Mon Feb  3 14:44:46 2014
Modify: Mon Feb  3 14:44:46 2014
Change: Mon Feb  3 14:44:46 2014

mike@mikembp:~$ stat -x /Users/mike/
  File: "/Users/mike/"
  Size: 2958         FileType: Directory
  Mode: (0755/drwxr-xr-x)         Uid: (  501/    mike)  Gid: (   20/   staff)
Device: 1,2   Inode: 326834    Links: 87
Access: Sat May 18 08:22:51 2013
Modify: Fri Feb 21 07:40:46 2014
Change: Fri Feb 21 07:40:46 2014

20.2.14

Network and bandwidth monitoring with darkstat

I was searching for a networking monitor solution and found http://hints.macworld.com/article.php?story=20020521011343792

Darkstat's source code is available at http://unix4lyfe.org/darkstat/ After starting it runs as a daemon in the background.
mike@mikembp:~$ sudo darkstat -i en0
It binds itself to the TCP port 667 which can be changed and also other things:
mike@mikembp:~$ darkstat --help
darkstat 3.0.718 (using libpcap version 1.1.1)

usage: darkstat [ -i interface ]
                [ -f filter ]
                [ -r capfile ]
                [ -p port ]
                [ -b bindaddr ]
                [ -l network/netmask ]
                [ --base path ]
                [ --local-only ]
                [ --snaplen bytes ]
                [ --pppoe ]
                [ --syslog ]
                [ --verbose ]
                [ --no-daemon ]
                [ --no-promisc ]
                [ --no-dns ]
                [ --no-macs ]
                [ --no-lastseen ]
                [ --chroot dir ]
                [ --user username ]
                [ --daylog filename ]
                [ --import filename ]
                [ --export filename ]
                [ --pidfile filename ]
                [ --hosts-max count ]
                [ --hosts-keep count ]
                [ --ports-max count ]
                [ --ports-keep count ]
                [ --highest-port port ]
                [ --wait secs ]
                [ --hexdump ]
                [ --version ]
                [ --help ]


Additional resources, info:
https://thejimmahknows.com/network-monitoring-ntop-vs-darkstat/ http://slackblogs.blogspot.com/2011/06/monitor-traffic-usage-using-darkstat.html

Disk SMART capability

I came across http://unix4lyfe.org/trim/ and became curious about my disk info so I installed smartmontools
mike@mikembp:~/Sites/atechcomp$ sudo port install smartmontools
Password:
--->  Fetching archive for smartmontools
--->  Attempting to fetch smartmontools-6.2_0+attributelog+savestates.darwin_12.x86_64.tbz2 from http://packages.macports.org/smartmontools
--->  Attempting to fetch smartmontools-6.2_0+attributelog+savestates.darwin_12.x86_64.tbz2.rmd160 from http://packages.macports.org/smartmontools
--->  Installing smartmontools @6.2_0+attributelog+savestates
--->  Activating smartmontools @6.2_0+attributelog+savestates
--->  Cleaning smartmontools
--->  Updating database of binaries: 100.0%
--->  Scanning binaries for linking errors: 100.0%
--->  No broken files found.

My Intel SSD info
mike@mikembp:~/Sites/atechcomp$ smartctl -i /dev/disk0
smartctl 6.2 2013-07-26 r3841 [x86_64-apple-darwin12.3.0] (local build)
Copyright (C) 2002-13, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Family:     Intel 520 Series SSDs
Device Model:     INTEL SSDSC2BW120A3
Serial Number:    CVCV313309P4120BGN
LU WWN Device Id: 5 5cd2e4 000079310
Firmware Version: 400i
User Capacity:    120,034,123,776 bytes [120 GB]
Sector Size:      512 bytes logical/physical
Rotation Rate:    Solid State Device
Device is:        In smartctl database [for details use: -P show]
ATA Version is:   ACS-2 T13/2015-D revision 3
SATA Version is:  SATA 3.0, 6.0 Gb/s (current: 6.0 Gb/s)
Local Time is:    Thu Feb 20 08:22:02 2014 CET
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

Info for the stock Apple HDD in MBP 2011
mike@mikembp:~/Sites/atechcomp$ smartctl -i /dev/disk1
smartctl 6.2 2013-07-26 r3841 [x86_64-apple-darwin12.3.0] (local build)
Copyright (C) 2002-13, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Device Model:     Hitachi HTS545032B9A302
Serial Number:    110216PBSC00PYJ5TSES
LU WWN Device Id: 5 000cca 673ded1cb
Firmware Version: PB3AC60Y
User Capacity:    320,072,933,376 bytes [320 GB]
Sector Size:      512 bytes logical/physical
Rotation Rate:    5400 rpm
Device is:        Not in smartctl database [for details use: -P showall]
ATA Version is:   ATA8-ACS T13/1699-D revision 6
SATA Version is:  SATA 2.6, 3.0 Gb/s
Local Time is:    Thu Feb 20 08:22:06 2014 CET
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

18.2.14

Facebook group posts on own webpage in PHP

A friend needed his FB groups posts embedded on his webpage so here are some snippets that I don't forget :D
  1. At https://developers.facebook.com create a new APP, after creating you get the required ID and SECRET.
  2. From https://github.com/facebook/facebook-php-sdk download the PHP SDK

require_once(WB_PATH."/include/facebook/src/facebook.php"); // Get from https://github.com/facebook/facebook-php-sdk

$APP_ID = 'APPID';
$APP_SECRET = 'APPSECRET';
$GROUP_ID = 'GROUPID';

$config = array(
    'appId' => $APP_ID,
    'secret' => $APP_SECRET,
    'fileUpload' => false,
    'allowSignedRequest' => false,
);

$facebook = new Facebook($config);
extract($facebook->api("/$GROUP_ID/feed?limit=10"));

$posts = '';
foreach ($data as $d) {
    if (!empty($d['message'])) {
        $posts .= '
  • '.date('d.m.Y H:i', strtotime($d['created_time'])).'

    '.$d['message'].'

  • '; } }

    During googling I found http://pastebin.com/LPnzUQSF, but I didn't try.

    17.2.14

    Firefox or other browser not parsing CSS or JS file

    Today thanks to mozilla #css IRC channel I learned and experienced why isn't Firefox loading some CSS and JS files for a particular page.
    ALWAYS CHECK YOUR EXTENSIONS BEHAVIOUR


    16.2.14

    Catch dtruss output into a file

    After some googling and not finding the solution I tried from the previous googled sites the following:
    sudo dtruss -ap 38961 2> /tmp/ff.log
    
    And it worked ! :)

    How to clean up of a 600GB backup

    Here are some thoughts about cleaning up data after a backup, recovery or restoration.

    Rsync stats from one USB harddrive to another, it took over 17 hours during which I was away from home :)



    My bigger problem was that I needed to manualy scan the images, due some partition recovery incident. The directory contained 103541 JPGs that was 12 GB of data. For moving just the wider photos (width over 800px) to a separate dir I used the following command:
    for f in *.jpg;do if [ `identify "$f" | cut -f3 -d ' ' | cut -f1 -d x` -gt 800 ] ; then mv "$f" big/;fi;done
    

    Listing with specified first character was very handy, which also worked for moving or removing:
    localhost:/tmp/backup$ ls [a]*.jpg
    localhost:/tmp/backup$ ls [b,B]*.jpg
    
    Some digital cameras start naming the photo files with IMG, DSC, P, ..., so I moved them to reduce some searching:
    localhost:/tmp/backup: mv IMG* ../jpg
    localhost:/tmp/backup: mv DSC* ../jpg
    localhost:/tmp/backup: mv P* ../jpg
    

    Next I moved the files containing year numbers
    localhost:/tmp/backup: mv *2013* ../jpg/2013
    localhost:/tmp/backup: mv *2012* ../jpg/2012
    
    Moving files according to their file types is also handy:
    localhost:/tmp/backup$ mv `find . -name "*sql"` ../sql/
    localhost:/tmp/backup$ mv `find . -name "*zip"` ../zip/
    

    If you getting error /bin/rm: Argument list too long., then try:
    find . -name '*.php' -print0 | xargs -0 rm
    

    Find empty directories and remove them:
    find . -type d -empty -exec rm -r {} \;
    

    Some PHP security goodness, how-to

    Some of my best practites for PHP

    1. Check the syntax of all of the php files:
    localhost:~ $ find $(pwd) -name \*.php -exec php -l '{}' \;
    

    2. Set php.ini for development:
    error_reporting=8192
    display_errors=On
    display_startup_errors=On
    log_errors=On
    error_log=error_log
    report_memleaks=On
    expose_php=On
    asp_tags=Off
    

    3. Watch out for proper type handling:
    $clean_int = (int)$dangerous_int;
    
    4. Watch apache/error_log for errors while running a link checker on the site (try also for authenticated user):
    tail -f /var/log/apache2/error_log
    
    More resources:
    http://blackhatlibrary.net/PHP http://www.phptherightway.com/

    Linux special case listing options, tricks

    To list only files beginning with the specified character:

    mike@jarvis:/media/sdb1/jpg$ ls -1 [A]*.jpg
    A-AM11-GGD_icon01_s_1.jpg
    A-AM11-GGD_icon01_s.jpg
    A-AM13-GGD_icon02_s_1.jpg
    A-AM13-GGD_icon02_s.jpg
    
    mike@jarvis:/media/sdb1/jpg$ ls -1 [a]*.jpg
    a001_1.jpg
    a001.jpg
    a002_1.jpg
    a002.jpg
    a003_1.jpg
    a003.jpg
    a004_1.jpg
    a004.jpg
    a005_1.jpg
    a005.jpg
    
    Finding PNG images greater than 800 pixels:
    for f in *.png;do if [ `file $f | cut -f5 -d\ ` -gt 800 ] ; then echo $f;fi;done
    
    Finding JPG images greater than 800 pixels (requires installed imagemagick, to have identify command):
    for f in *.jpg;do if [ `identify "$f" | cut -f3 -d ' ' | cut -f1 -d x` -gt 800 ] ; then echo "$f";fi;done
    

    Resources that can also help:
    http://www.codecoffee.com/tipsforlinux/articles/26-1.html http://www.thegeekstuff.com/2009/07/linux-ls-command-examples/ http://www.cyberciti.biz/faq/linux-list-just-directories-or-directory-names/