Chicken Skin

  • Contact
  • Portfolio
  • Sys Admin
  • Random
  • Archive
  • RSS

Check Sparc Firmware

root@hostname:/# prtdiag -v|grep OBP

    • #unix
    • #solaris
    • #obp
    • #firmware
    • #prtdiag
  • 1 year ago
  • 14
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+
Pop-upView Separately
    • #unix
    • #dilbert
    • #funny
    • #server
    • #computer
    • #humor
  • 1 year ago
  • 8
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+

Encrypting a tar file using openssl
In some cases, you may have to send your datacenter’s passwd information to some of your collegues. Instead of sending them in plain text, you can use tar & openssl combination to encrypt that data. Here is how it can be done.

Encryption :

Tar & gzip the password file and encrypt using openssl des3 and a secret key. Replace the text “secretkey” with your secret password.

[root@unixfoo-lin23 ~]# tar cvzf - passwd_info.txt | openssl des3 -salt -k secretkey | dd of=encrypted_passwd_info
passwd_info.txt
20+1 records in
20+1 records out

The filetype of the encrypted file is “data” and you cannot use “tar -tvzf” to list contents on this.

[root@unixfoo-lin23 ~]# file encrypted_passwd_info
encrypted_passwd_info: data

[root@unixfoo-lin23 ~]# tar tvzf encrypted_passwd_info
gzip: stdin: not in gzip format
tar: Child returned status 1
tar: Error exit delayed from previous errors
[root@unixfoo-lin23 ~]#


Decryption :

While decrypting the file, use the steps below. Replace the text “secretkey” with your secret password which you provided during encryption.

[root@unixfoo-lin12 ~]# dd if=encrypted_passwd_info |openssl des3 -d -k secretkey |tar xvzf -
20+1 records in
20+1 records out
passwd_info.txt
[root@unixfoo-lin12 ~]# cat passwd_info.txt | head -1
UNIX User UNIX Password
[root@unixfoo-lin12 ~]#

This method can also be used to gzip and encrypt any file or directory.

unixfoo

Source: unixfoo.blogspot.com

    • #linux
    • #unix
    • #solaris
    • #opensource
    • #ssl
    • #tar
    • #compress
    • #encrypt
    • #password
    • #key
    • #secret
  • 1 year ago
  • 5
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+

RAID Levels Explained

I always forget which one is mirroring 

    • #it
    • #unix
    • #linux
    • #solaris
    • #computers
    • #raid
  • 1 year ago
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+

Nice lvm discussion

    • #linux
    • #unix
    • #lvm
    • #fedora
    • #Red hat
    • #suse
    • #Opensuse
  • 1 year ago
  • 2
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+
'\x3ciframe width=\x22500\x22 height=\x22307\x22 src=\x22http://www.youtube.com/embed/yLQlGqHpM9A?wmode=transparent\x26autohide=1\x26egm=0\x26hd=1\x26iv_load_policy=3\x26modestbranding=1\x26rel=0\x26showinfo=0\x26showsearch=0\x22 frameborder=\x220\x22 allowfullscreen\x3e\x3c/iframe\x3e'

MySQL Cluster: An Introduction (by tcation)

Source: youtube.com

    • #unix
    • #linux
    • #mysql
    • #ha
    • #cluster
  • 1 year ago
  • 19
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+
Good habit #1: Defining complex directory trees with one command

~ $ mkdir -p project/{lib/ext,bin,src,doc/{html,info,pdf},demo/stat/a}
http://www.ibm.com/developerworks/aix/library/au-badunixhabits.html
    • #Unix
    • #Linux
    • #System administration
    • #it
    • #computers
    • #command line
    • #cli
    • #mkdir
  • 1 year ago
  • 5
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+
I spent the whole day prepping a Solaris machine for an Oracle database installation. According to Oracle’s white paper that describes deploying oracle on ZFS, putting oracles file systems into separate pools is the way to go. I arranged my pools like this:
root@swan:/etc# zpool list      
NAME              SIZE  ALLOC   FREE    CAP  HEALTH  ALTROOT
swan-collector     516G  76.5K   516G     0%  ONLINE  -
swan-db-pool      928G   249K   928G     0%  ONLINE  -
swan-exportpool   278G   117K   278G     0%  ONLINE  -
swan-redopool1    105G   117K   105G     0%  ONLINE  -
swan-redopool2    106G   117K   106G     0%  ONLINE  -
swan_zpool       59.5G  7.45G  52.1G    12%  ONLINE  -
The Database admins I work with like having 2 redo directories in case one blows up. This being the test environment I took a liberty of doing something different as I continue to explore ZFS. 
In the development version of this machine I gave the db-pool on big lun. The machine’s users raved about its performance. But one of the documents over at SolarisInternals helped me to discern that splitting the load over 2 disk might yield better performance. We will see. I am going try to use some of the Dtrace  knowledge I have been picking up to figure up some way to test this stuff out.
Setting quotas in zfs? Super easy since you dont want your file systems to get full. You can take an unpleasant performance hit if a file system that gets a lot of activity gets to  be over 20% full. Here is the command
zfs set quota=100G pool/filesystem 
It will show up in DF as having a max capacity of the quoted amount.
Pop-upView Separately

I spent the whole day prepping a Solaris machine for an Oracle database installation. According to Oracle’s white paper that describes deploying oracle on ZFS, putting oracles file systems into separate pools is the way to go. I arranged my pools like this:

root@swan:/etc# zpool list      

NAME              SIZE  ALLOC   FREE    CAP  HEALTH  ALTROOT

swan-collector     516G  76.5K   516G     0%  ONLINE  -

swan-db-pool      928G   249K   928G     0%  ONLINE  -

swan-exportpool   278G   117K   278G     0%  ONLINE  -

swan-redopool1    105G   117K   105G     0%  ONLINE  -

swan-redopool2    106G   117K   106G     0%  ONLINE  -

swan_zpool       59.5G  7.45G  52.1G    12%  ONLINE  -

The Database admins I work with like having 2 redo directories in case one blows up. This being the test environment I took a liberty of doing something different as I continue to explore ZFS. 


In the development version of this machine I gave the db-pool on big lun. The machine’s users raved about its performance. But one of the documents over at SolarisInternals helped me to discern that splitting the load over 2 disk might yield better performance. We will see. I am going try to use some of the Dtrace  knowledge I have been picking up to figure up some way to test this stuff out.

Setting quotas in zfs? Super easy since you dont want your file systems to get full. You can take an unpleasant performance hit if a file system that gets a lot of activity gets to  be over 20% full. Here is the command

zfs set quota=100G pool/filesystem 

It will show up in DF as having a max capacity of the quoted amount.

Source: rashardkelly.com

    • #storm
    • #zfs
    • #solaris
    • #unix
    • #linux
  • 1 year ago
  • 5
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+
ZFS tidbits of the Day
Im not totally clear on this but it appears that to properly send a zfs filesystem from one pool all the skeleton file systems have to be created on the reciving pool for things to go smoothly. Here is an example of creating a snapshot on one pool and sending it to another
First create the snapshot of your filesystem
# zfs snapshot -r pool/filesystem@snapshotnameList out your ZFS filesystems to make sure you created the snapshot
# zfs list
NAME                                         USED  AVAIL  REFER  MOUNTPOINTpool/filesystem                             2.13G  50.1G  2.13G  /snapspool/filesystem@snapshotname    23K      -  2.13G  -
If you would like to experiment with rolling a snapshot back use this command after making some changes to the file system you can go back to your directories former contents
# zfs rollback -r pool/filesystem@snapshotnameAfter playing with that a bit create your new zfs filesystems within the pool you are sending the data to.
# zfs create newpool/filesystem
Now we can import the snapshot into our new pool and all the data will magically be moved!
# zfs send pool/filesystem@snapshotname |  zfs receive -F  newpool/filesystem
Set a mount point for the new filesystem and BOOM! you just sent an entire filesystem to a new device without rsync fouling things up. this can also be done over ssh.
host1# zfs send -i tank/dana@snap2 tank/dana@snap3 | ssh host2 zfs recv -F newtank/danaSSh example obtained from here
Pop-upView Separately

ZFS tidbits of the Day

Im not totally clear on this but it appears that to properly send a zfs filesystem from one pool all the skeleton file systems have to be created on the reciving pool for things to go smoothly. Here is an example of creating a snapshot on one pool and sending it to another

First create the snapshot of your filesystem

# zfs snapshot -r pool/filesystem@snapshotname

List out your ZFS filesystems to make sure you created the snapshot

# zfs list

NAME                                         USED  AVAIL  REFER  MOUNTPOINT
pool/filesystem                             2.13G  50.1G  2.13G  /snaps
pool/filesystem@snapshotname    23K      -  2.13G  -

If you would like to experiment with rolling a snapshot back use this command after making some changes to the file system you can go back to your directories former contents

# zfs rollback -r pool/filesystem@snapshotname

After playing with that a bit create your new zfs filesystems within the pool you are sending the data to.

# zfs create newpool/filesystem

Now we can import the snapshot into our new pool and all the data will magically be moved!

# zfs send pool/filesystem@snapshotname |  zfs receive -F  newpool/filesystem

Set a mount point for the new filesystem and BOOM! you just sent an entire filesystem to a new device without rsync fouling things up. this can also be done over ssh.

host1# zfs send -i tank/dana@snap2 tank/dana@snap3 | ssh host2 zfs recv -F newtank/dana
SSh example obtained from here
    • #IT
    • #airvac
    • #bash
    • #send
    • #send
    • #solaris
    • #system administration
    • #unix
    • #zfs
    • #linux
  • 1 year ago
  • 2
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+

Replace text globally in VIM

Vim!

: - Get to command mode

 This command will replace all the text in a file!

1,%s/old/new/g  

1= start from line 1

,= just a delimiter to separate the range values.

% = to end of file you can set this to be a number as well like if you only want to replace the text between lines 10 and 50.

g= global

    • #unix
    • #it
    • #computers
    • #VI
    • #vim
    • #linux
  • 1 year ago
  • 1
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+
Wow I LOVE LilyTerm!! Much more responsive than Konsole or Terminal.app on Mac OSX! Im in love again. The tabe are great and you can simply use CTRL + C or V to copy and paste! So simple and compact!
Pop-upView Separately

Wow I LOVE LilyTerm!! Much more responsive than Konsole or Terminal.app on Mac OSX! Im in love again. The tabe are great and you can simply use CTRL + C or V to copy and paste! So simple and compact!

    • #IT
    • #computers
    • #emulator
    • #fedora
    • #lilyterm
    • #linux
    • #terminal
    • #unix
  • 1 year ago
  • 4
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+

Make Bash even Sexier!

Great page to customize bash prompts to your liking.

    • #color
    • #unix
    • #pretty
    • #custom
    • #linux
    • #solaris
    • #shell
  • 2 years ago
  • 2
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+

Great Solaris Volume Manager Tutorial

    • #unix
    • #solaris
    • #ufs
  • 2 years ago
  • 2
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+

Adding Swap under ZFS

    • #zfs
    • #unix
    • #solaris
    • #IT
    • #computers
  • 2 years ago
  • 1
  • Permalink
Share

Short URL

TwitterFacebookPinterestGoogle+
Page 1 of 2
← Newer • Older →

Chicken Skin

About

Avatar

Top

  • RSS
  • Random
  • Archive
  • Mobile
Effector Theme by Pixel Union