23rd April 2012

Post

Booting live Linux distributions with grub2

This is primarily for my reference, maybe someone else will find it useful.

I like SystemRescueCd, despite the fact that is Gentoo based, but I don’t like its USB installer, I simply don’t. So I had to find out a way to boot it directly from the ISO image, this would also have been useful with upgrades: download the new image and copy it to the stick.

Later this idea proved to be useful to boot different Linux distributions from the same key, without the need to extract them and the use of available Windows only tools which honestly I don’t trust.

You need to install grub2 on the stick. This is the grub.conf I came up with  for Systemrescuecd (and its external tools), Parted magic, GRML32 (really never used, but who knows?), Clonezilla and a Debian netinstall. Entries are self explanatory.

menuentry “SystemRescueCd i386” {
        loopback loop /systemrescuecd.iso
        linux (loop)/isolinux/rescuecd isoloop=systemrescuecd.iso setkmap=it nomodeset
        initrd (loop)/isolinux/initram.igz
}

menuentry “SystemRescueCd x64” {
        loopback loop /systemrescuecd.iso
        linux (loop)/isolinux/rescue64 isoloop=systemrescuecd.iso setkmap=it nomodeset
        initrd (loop)/isolinux/initram.igz
}

menuentry “Parted Magic” {
    loopback loop /pmagic.iso
    linux (loop)/pmagic/bzImage iso_filename=/pmagic.iso boot=live load_ramdisk=1 prompt_ramdisk=0 keymap=it noeject noprompt
    initrd (loop)/pmagic/initrd.img
}

menuentry “GRML32” {
        loopback loop /grml32.iso
        linux (loop)/boot/grml32/vmlinuz findiso=/grml32.iso boot=live apm=power-off gfxpayload=text
        initrd (loop)/boot/grml32/initrd.img
}

menuentry “Clonezilla” {
    loopback loop /clonezilla.iso
    linux (loop)/live/vmlinuz root=(loop)/ rootfstype=loop findiso=/clonezilla.iso boot=live noswap config  noswap nolocales edd=on nomodeset ocs_live_run=”ocs-live-general” ocs_live_batch=”no” nomodeset vga=normal
    initrd (loop)/live/initrd.img
}

menuentry “SystemRescueCd - memtest” {
        loopback loop /systemrescuecd.iso
        linux16 (loop)/bootdisk/memtestp
}

menuentry “SystemRescueCd - ntpass” {
        loopback loop /systemrescuecd.iso
        linux16 (loop)/ntpasswd/vmlinuz rw vga=1
    initrd16 (loop)/ntpasswd/initrd.cgz
    initrd16 (loop)/ntpasswd/scsi.cgz
}

menuentry “SystemRescueCd - freedos” {
        loopback loop /systemrescuecd.iso
        linux16 (loop)/isolinux/memdisk
    initrd16 (loop)/bootdisk/freedos.img floppy
}

menuentry “SystemRescueCd - hardware diagnostic” {
        loopback loop /systemrescuecd.iso
        linux16 (loop)/isolinux/memdisk
        initrd16 (loop)/bootdisk/hdt.img floppy
}

menuentry “SystemRescueCd - ranish pman” {
        loopback loop /systemrescuecd.iso
        linux16 (loop)/isolinux/memdisk
        initrd16 (loop)/bootdisk/ranish.img floppy
}

menuentry “SystemRescueCd - low level hdd” {
        loopback loop /systemrescuecd.iso
        linux16 (loop)/isolinux/memdisk
        initrd16 (loop)/bootdisk/mhdd.img floppy
}

menuentry “Debian i386 install” {
    loopback loop /debian-6.0.4-i386-CD-1.iso
        linux (loop)/install.386/vmlinuz
        initrd (loop)/install.386/initrd.gz
}

Tagged: USBclonezillagrublinuxpartedmagicsystemrescuecd

18th November 2011

Photo reblogged from Chi ti ha dato la patente? with 34 notes

incivili:

Via Solari, Milano, segnali di inciviltà: un avviso che rivendica la necessità, per il bene dei negozianti, di parcheggiare in divieto, in doppia fila, apparso solo qualche giorno dopo la morte di un ragazzino di dodici anni, investito da un un tram mentre era in bici in una strada dove vige(va) il parcheggio selvaggio.
(grazie a @pinkmrt)

incivili:

Via Solari, Milano, segnali di inciviltà: un avviso che rivendica la necessità, per il bene dei negozianti, di parcheggiare in divieto, in doppia fila, apparso solo qualche giorno dopo la morte di un ragazzino di dodici anni, investito da un un tram mentre era in bici in una strada dove vige(va) il parcheggio selvaggio.

(grazie a @pinkmrt)

Source: incivili

30th July 2011

Post with 47 notes

Network Attached Storages and Cisco vPC

Today I had to deal with a strange issue: a client reported that some hosts weren’t able to reach a NAS, an EMC Celerra NS-120. These hosts didn’t have any special configuration and were on the same access switches of others that were working perfectly.

The network has a couple of Cisco Nexus 7000 as core switches, interconnected via vPC (a link aggregation technology that allows to create multi chassis ether channels retaining control plane separation); they perform all the routing and are configured with HSRP.

A packet capture revealed that the NAS was receiving the packets and replying to them, but something was off: instead of using the HSRP virtual MAC address of the router they tried to reach the destination via the hardwired MAC of the Nexus which the request was routed through. Weird, but usually it shouldn’t be a problem, why frames were dropped and where?

When a vPC enabled device receives a packet from the peer link it won’t forward it to other links of the same vPC domain, to prevent frame duplication, the peer will take care of them, simple as that.

But in this case core2 was forced to receive the return traffic and the access switch is connected via vPC, but hey! core1 didn’t send those frames along his side of the vPC, since they weren’t addressed to it, dropped. But wait a minute, the access switch has two links, why those host were using always the one to core2? Load balacing decision is performed on the source MAC address by default, by hashing it into a (binary in this case) outcome, same NIC, same link, same router (even if it’s the standby one, with vPC all the peers are forwarding).

It turns out that Celerras have this “feature” (meh) called packet reflect that will ignore routes and ARP caches, sending back replies directly to the source MAC. No thanks, I appreciate your effort to screw with my network, but I have HSRP, and you will use it.

SSH into the control station and issue:

server_param <movername> -facility ip -modify reflect -value 0

problem solved, 4 hours lost.

PS: as a temporary workaround I had added to core2 a single IP route to reach the NAS via core1, it works but it is definitely not nice.

PS2: knowing the name of this feature, I found a blog post where this issue is solved on the Nexus: with vpc peer-gateway they will accept frames destined for their vPC peers. Neat, I’ll give it some thought.

Tagged: CiscoNexusNX-OSvPCHSRPEMCCelerravpc peer-gatewaypacket reflect

23rd July 2011

Post with 1 note

Il tetto sugli sconti ai libri

Non mi è ancora chiaro come si intende attuare la legge anti-Amazon, considerato che hanno sede in Lussemburgo e spediscono da magazzini situati in EU.

Poi limite del 15% su quale prezzo? E se il libro non è pubblicato in Italia? Si fa una media sui prezzi praticati dagli importatori? E se il libro è pubblicato in Italia e volessi comprare un’edizione in italiano di un editore non italiano? E se si tratta di un e-book? E se volessi praticare sconti straordinari in occasione della Golden Week?

Il comma 9 recita:

Il comune vigila sul rispetto delle disposizioni del presente articolo e provvede all’accertamento e all’irrogazione delle sanzioni previste al comma 8; i relativi proventi sono attribuiti al comune nel quale le violazioni hanno avuto luogo.

ho capito bene nella mia ignoranza di materie legislative? Si demanda ai comuni l’accertamento? In quale comune hanno luogo le violazioni quando esse avvengono in un altro stato dell’Unione? Le sezioni di polizia annonaria delle municipali istituiranno posti di blocco per i corrieri che consegnano gli ordini effettuati online?

19th July 2011

Quote with 1 note

We need to start by admitting that we screwed up. We have to listen to our community when they tell us what a serious problem this is for them.
— Jono Xia, Mozilla Labs, about Firefox new versioning scheme

30th April 2011

Photo reblogged from Chad Hurley.com with 53 notes

chadhurley:

Delicious!

Youtube founders Chad Hurley and Steve Chen bought delicious.com

chadhurley:

Delicious!

Youtube founders Chad Hurley and Steve Chen bought delicious.com

Source: chadhurley

4th March 2011

Post

uso privato

La cosa più paradossale in tutta la faccenda della prescrizione breve è che il Sen. Ghedini dichiari che la legge non serve al PresDelCons e quindi la proposta vada ritirata. Ormai non ci si nasconde nemmeno più dietro un dito, le leggi sulla riforma della Giustizia si fanno perché ne possa beneficiare il capo, il resto è tempo perso.

3rd March 2011

Post

Il nuovo che avanza

Il Consiglio dei Ministri ha nominato un novantenne quale commissario straordinario della SIAE. Sicuramente una persona in grado di comprendere appieno i molteplici aspetti della rete e degli stravolgimenti che ha portato nel mercato musicale e cinematografico

6th February 2011

Post with 1 note

La rumenta

Oggi si è tenuta Genoa-Milan, le tifoserie delle due squadre non si possono vedere e qualche anno fa (16) c’è scappato il morto, ne consegue che tutte le volte che le due squadre si incontrano è emergenza cittadina: auto delle forze dell’ordine ad ogni incrocio, divieti di sosta a perdita d’occhio, deviazioni del traffico e cassonetti dei rifiuti rimossi per un tratto di strada di 5km (per difetto). Cinque chilometri lineari di strada di cassonetti e campane per il riciclaggio asportati e ammassati chissà dove in una notte, verranno ripristinati quella successiva, con tutte le vie e i quartieri periferici è una quantità semplicemente ridicola.

Dice: “ma tanto la domenica è vietato depositare i rifiuti”, a parte che non capisco perché ristoranti e bar sì ed io no, ma lasciamo stare. Questo giochetto di prestigio lo pago io con la mia TARSU, già esosissima, non le società sportive, come devo pagare la ripulitura delle zone lordate dal passaggio delle cavallette multicolori ogni domenica e anche i costosissimi lavori di manutenzione dello stadio, che è comunale, e per il cui uso le suddette società devono ancora pagare milioni di euro di arretrati.

In tutto questo il fatto che io ritenga il calcio uno sport per sottosviluppati è una coincidenza.

6th February 2011

Quote with 1 note

When they first came to office, the Obama team had a mantra: “Never waste a good crisis”. They then spent the next two years doing exactly the opposite.

Tagged: twitteregyptobama