Skip to content

Instantly share code, notes, and snippets.

ilovezfs / gist:8730681
Created January 31, 2014 11:51
openLUKS from prometheanfire
openLUKS() {
read -s -p "Password: " password
echo ""
while [ $RETRY_COUNT -ne 0 ]; do
for disk in a b c d e f g h i j k l m n o p q r s t u v w x y z; do
if [ -b /dev/sd${disk}2 ]; then
echo -n ${password} | gpg -q -d --no-tty --passphrase-fd 0 /mnt/key/decrypt.gpg | cryptsetup -q --key-file=- luksOpen /dev/sd${disk}2 crypt${disk}2
sudo rm -rf /System/Library/Extensions/zfs.kext
sudo rm -rf /System/Library/Filesystems/zfs.fs
sudo rm -f /usr/lib/libzfs.dylib
sudo rm -f /usr/lib/libzpool.dylib
sudo rm -f /usr/local/bin/zoink
sudo rm -f /usr/sbin/zfs
sudo rm -f /usr/sbin/zpool
ilovezfs /
Created March 6, 2014 16:19
rm -rf /System/Library/Extensions/spl.kext
rm -rf /usr/src/spl-*
rm -rf /System/Library/Extensions/zfs.kext
rm -rf /usr/src/zfs-*
rm -rf /usr/lib/modules-load.d
rm -rf /usr/lib/systemd
rm -rf /usr/local/etc/init.d
rm -rf /usr/local/etc/zfs/
rm -rf /usr/local/include/libspl
ilovezfs /
Last active August 29, 2015 13:57
sudo kextunload -b net.lundman.zfs
sudo kextunload -b net.lundman.spl
cd /System/Library/Extensions
sudo rm -rf spl.kext
sudo rm -rf zfs.kext
cd /Library/Extensions
sudo rm -rf spl.kext
ilovezfs / org.openzfsonosx.zfs.zed.plist.xml
Created April 19, 2014 04:47
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "">
<plist version="1.0">
ilovezfs / gist:11180643
Created April 22, 2014 14:08
rollback abort
Process: zfs [21220]
Path: /Users/*/zfs
Identifier: zfs
Version: 0
Code Type: X86-64 (Native)
Parent Process: sudo [21219]
User ID: 0
Date/Time: 2014-04-22 07:05:46.496 -0700
OS Version: Mac OS X 10.8.5 (12F45)
diff --git a/lib/libefi/rdwr_efi.c b/lib/libefi/rdwr_efi.c
index 68ee076..09b277e 100644
--- a/lib/libefi/rdwr_efi.c
+++ b/lib/libefi/rdwr_efi.c
@@ -113,7 +113,7 @@ struct dk_map2 default_vtoc_map[NDKMAP] = {
#endif /* defined(_SUNOS_VTOC_16) */
-#ifdef DEBUG
+#ifndef DEBUG
ilovezfs /
Created May 19, 2014 10:25 (no -j)
#!/usr/bin/env bash
# zfsadm, originated by ilovezfs, licensed under GPLv3
# Suggested workflows:
# 1) Run zfsadm with no options, in order to fetch and build ZFS.
# 2) Then, you may do one of these:
# 2a) Run 'zfsadm -k' to manually load the resulting suite, and use
# 'sudo ./ zfs ...', 'sudo ./ zpool ...', etc.
# 2b) Install the resulting suite using 'sudo make install' in each of
# their respective directories: ~/Developer/spl and ~/Developer/zfs.
ilovezfs / gist:c318ef6032fc9182cb55
Last active August 29, 2015 14:02
pool in pool
Josephs-MacBook-Pro:zfs joe$ dd if=/dev/zero of=poolonzvol.bin bs=1m count=256
256+0 records in
256+0 records out
Josephs-MacBook-Pro:zfs joe$ sudo ./ zpool create outter `pwd`/poolonzvol.bin
Josephs-MacBook-Pro:zfs joe$ sudo ./ zpool status
pool: outter
state: ONLINE
scan: none requested