Skip to content

Instantly share code, notes, and snippets.

View kylejohnson's full-sized avatar

Kyle Johnson kylejohnson

View GitHub Profile
#!/bin/sh
i3status | while :
do
read line
pbpid=$(pidof pianobar)
if [[ "$pbpid" ]]; then
currentSong=~/.config/pianobar/currentSong
@kylejohnson
kylejohnson / gist:8fd7c8c6e84b52121f37628354ed895b
Created September 6, 2016 18:52
compiling glusterfs on freebsd
[kyle@colossus2 ~]$ git clone https://github.com/gluster/glusterfs.git
[kyle@colossus2 ~]$ cd glusterfs
[kyle@colossus2 ~/glusterfs]$ vim glusterfsd/src/Makefile.am
...
[kyle@colossus2 ~/glusterfs]$ vim glusterfsd/src/glusterfsd.c
...
[kyle@colossus2 ~/glusterfs]$ git diff
diff --git a/glusterfsd/src/Makefile.am b/glusterfsd/src/Makefile.am
index 0f83622..20eabd1 100644
[2016-07-20 15:05:11.395007] I [MSGID: 100030] [glusterfsd.c:2340:main] 0-/usr/local/sbin/glusterfsd: Started running /usr/local/sbin/glusterfsd version 3.7.13 (args: /usr/local/sbin/glusterfsd -s 192.168.110.1 --volfile-id ftp.192.168.110.1.tank-bricks-ftp -p /var/db/glusterd/vols/ftp/run/192.168.110.1-tank-bricks-ftp.pid -S /var/run/gluster/7b70d13d88d41991bb7fb46b49ca2173.socket --brick-name /tank/bricks/ftp -l /var/log/glusterfs/bricks/tank-bricks-ftp.log --xlator-option *-posix.glusterd-uuid=d789fa29-1eae-46d9-a217-3a2ee23373cd --brick-port 49159 --xlator-option ftp-server.listen-port=49159)
[2016-07-20 15:05:11.404161] W [MSGID: 101095] [xlator.c:199:xlator_dynload] 0-xlator: Cannot open "/usr/local/lib/glusterfs/3.7.13/xlator/features/changetimerecorder.so"
[2016-07-20 15:05:11.404231] E [graph.y:212:volume_type] 0-parser: Volume 'ftp-changetimerecorder', line 16: type 'features/changetimerecorder' is not valid or not found on this machine
[2016-07-20 15:05:11.404282] E [graph.y:321:volume_end] 0-parse
root@colossus2:~ # zfs get all tank/bricks
NAME PROPERTY VALUE SOURCE
tank/bricks type filesystem -
tank/bricks creation Wed Jun 22 8:15 2016 -
tank/bricks used 37.6T -
tank/bricks available 12.7T -
tank/bricks referenced 37.6T -
tank/bricks compressratio 1.00x -
tank/bricks mounted yes -
tank/bricks quota none default
https://gist.github.com/kylejohnson/d1e4d37e25f1309f85721284222a639b
root@colossus ~]# gluster volume create fubar 192.168.110.2:/ftp/bricks/fubar
volume create: fubar: success: please start the volume to access data
[root@colossus ~]# gluster volume start fubar
volume start: fubar: success
[root@colossus ~]# mount -t glusterfs 192.168.110.2:/fubar /mnt/test
[root@colossus ~]# touch /mnt/test/file{1..100}
[root@colossus ~]# ls /mnt/test/| wc -l
100
[root@colossus ~]# ls /ftp/bricks/fubar | wc -l
100
root@colossus2:~ # getextattr -x user trusted.glusterfs.volume-id /tank/bricks/ftp/
/tank/bricks/ftp/ fffffff3 fffffff2 ffffffb2 22 57 5c 4c ffffff8d ffffff92 fffffff1 ffffffe6 40 fffffffd 7e ffffffdf ffffffb
Ubuntu 12
Arch Linux ARM 6
Arch Linux 5
Debian GNU/Linux 5
Fedora 2
Gentoo 2
CentOS Linux 1
CentOS release 1
zm1 /home/kjohnson/ZoneMinder/scripts/ZoneMinder >make --makefile=MakefilePerl pure_install
make: don't know how to make pure_install. Stop
make: stopped in /usr/home/kjohnson/ZoneMinder/scripts/ZoneMinder
make -f scripts/ZoneMinder/CMakeFiles/zmperlmodules.dir/build.make scripts/ZoneMinder/CMakeFiles/zmperlmodules.dir/build
[ 96%] Building ZoneMinder perl modules
cd /home/kjohnson/ZoneMinder/scripts/ZoneMinder && perl Makefile.PL INSTALLDIRS=vendor NO_PACKLIST=1 NO_PERLLOCAL=1 FIRST_MAKEFILE=MakefilePerl DESTDIR="/home/kjohnson/ZoneMinder/scripts/ZoneMinder/output"
Generating a Unix-style MakefilePerl
Writing MakefilePerl for ZoneMinder
Writing MYMETA.yml and MYMETA.json
cd /home/kjohnson/ZoneMinder/scripts/ZoneMinder && make --makefile=MakefilePerl pure_install
make[3]: don't know how to make pure_install. Stop
make[3]: stopped in /usr/home/kjohnson/ZoneMinder/scripts/ZoneMinder