Sponsored Content
Top Forums Shell Programming and Scripting Is it possible to combine these two PS1 examples? Post 302638009 by Chubler_XL on Wednesday 9th of May 2012 06:31:22 PM
Old 05-09-2012
Try this:

Code:
date '+%H %M %S' | read H M S
SECONDS=$((S + 60*(60*H+M)))
PS1='${DUMMY[((S=(100+$SECONDS%60))+(M=(100+($SECONDS/60)%60))+(H=(100+($SECONDS/3600)%24)))*0]:-}'$(printf "\033[46;31m%s@\033[1;33m%s:\033[1;34m\$PWD \033[0m \033[1;33m\${H#1}:\${M#1}:\${S#1}\033[0m \$" $(logname) $(hostname))

 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

looking for .profile examples

I'm looking for some 'well documented' .profile examples (8 Replies)
Discussion started by: JimC
8 Replies

2. Shell Programming and Scripting

need examples?

Can someone give me an example of two shells? (1 Reply)
Discussion started by: wmosley2
1 Replies

3. Red Hat

redhat-release examples

I have a script that checks the redhat-release file to determine what security patch needs to be applied. Since there's a Red Hat 5 now, I need a redhat-release file from the various platforms (Desktop, Enteprise Workstation, and Enterprise Server) so I can build a proper search string. Also, it... (5 Replies)
Discussion started by: BOFH
5 Replies

4. UNIX for Advanced & Expert Users

Most useful Unix commands and Examples

These commands are placed in the MS Word Doc. with command options and the their respective examples. hope this will help for the beginners. Thanks. Varun Gupta:D (2 Replies)
Discussion started by: varungupta
2 Replies

5. UNIX for Dummies Questions & Answers

SimpleAWK Examples

Can Anyone please give me some simple AWK Examples to clearly understand the usage and syntax of the command. Thanks (2 Replies)
Discussion started by: unxusr123
2 Replies

6. Emergency UNIX and Linux Support

Awk and Sed examples

Hi all, I tried to understand what this awk and sed does but cudnt understand. Can any body explain what awk and sed means with one simple example each and complex examples each with explanation. Thanks in advance. (7 Replies)
Discussion started by: j_panky
7 Replies

7. UNIX for Advanced & Expert Users

Hard Link Examples

Hello, Please move this if I chose the wrong forum category. This question pertains to Unix and Linux I believe. I google the difference between hard and symbolic/soft links and I understand the difference. What I am trying to find is a real example of a hard link being used in a Operating... (11 Replies)
Discussion started by: jaysunn
11 Replies

8. Shell Programming and Scripting

lwp-request examples

Hi; Can i have ne sample examples of of using " lwp-request" in shell script. Is it necessary to have perl installed already in linux box for using this; Thnks; (2 Replies)
Discussion started by: ajaypadvi
2 Replies

9. Programming

Examples, usage, help in C++ program

I have written a C++ program to perform raytracing and would want to write some functions to help the user: examples, usage, help I am wondering how this is done. Would I just put some functions in the main program? (4 Replies)
Discussion started by: kristinu
4 Replies

10. Shell Programming and Scripting

Need lot of examples

Hi, I need a word doc or pdf which contains lots of Shell Programming samples... This is for my open book examination, thanks in advance.. (2 Replies)
Discussion started by: karthikeayan
2 Replies
GlusterFS(8)							   Gluster Inc. 						      GlusterFS(8)

NAME
GlusterFS - clustered file system SYNOPSIS
glusterfs [options] [mountpoint] DESCRIPTION
GlusterFS is a clustered file system, capable of scaling to several peta-bytes. It aggregates various storage bricks over Infiniband RDMA or TCP/IP and interconnect into one large parallel network file system. Storage bricks can be made of any commodity hardware, such as x86-64 server with SATA-II RAID and Infiniband HBA. GlusterFS is fully POSIX compliant file system. On client side, it has dependency on FUSE package, on server side, it works seemlessly on different operating systems. Currently supported on GNU/Linux and Solaris. OPTIONS
Basic options -f, --volfile=VOLUME-FILE File to use as VOLUME-FILE. -l, --log-file=LOGFILE File to use for logging (the default is <INSTALL-DIR>/var/log/glusterfs/<MOUNT-POINT>.log). -L, --log-level=LOGLEVEL Logging severity. Valid options are TRACE, DEBUG, INFO, WARNING, ERROR and CRITICAL (the default is INFO). -s, --volfile-server=SERVER Server to get the volume from. This option overrides --volfile option. --volfile-max-fetch-attempts=MAX-ATTEMPTS Maximum number of connect attempts to server. This option should be provided with --volfile-server option (the default is 1). Advanced options --acl Mount the filesystem with POSIX ACL support. --debug Run in debug mode. This option sets --no-daemon, --log-level to DEBUG, and --log-file to console. --enable-ino32=BOOL Use 32-bit inodes when mounting to workaround application that doesn't support 64-bit inodes. --fopen-keep-cache Do not purge the cache on file open. --mac-compat=BOOL Provide stubs for attributes needed for seamless operation on Macs (the default is off). -N, --no-daemon Run in the foreground. -p, --pid-file=PIDFILE File to use as PID file. --read-only Mount the file system in 'read-only' mode. --selinux Enable SELinux label (extended attributes) support on inodes. -S, --socket-file=SOCKFILE File to use as unix-socket. --volfile-id=KEY Key of the volume file to be fetched from the server. --volfile-server-port=PORT Port number of volfile server. --volfile-server-transport=TRANSPORT Transport type to get volume file from server (the default is tcp). --volume-name=VOLUME-NAME Volume name to be used for MOUNT-POINT (the default is top most volume in VOLUME-FILE). --worm Mount the filesystem in 'worm' mode. --xlator-option=VOLUME-NAME.OPTION=VALUE Add/Override a translator option for a volume with the specified value. Fuse options --attribute-timeout=SECONDS Set attribute timeout to SECONDS for inodes in fuse kernel module (the default is 1). --background-qlen=N Set fuse module's background queue length to N (the default is 64). --congestion-threshold=N Set fuse module's congestion threshold to N (the default is 48). --direct-io-mode=BOOL Enable/Disable the direct-I/O mode in fuse module (the default is enable). --dump-fuse=PATHR Dump fuse traffic to PATH --entry-timeout=SECONDS Set entry timeout to SECONDS in fuse kernel module (the default is 1). --gid-timeout=SECONDS Set auxilary group list timeout to SECONDS for fuse translator (the default is 0). --negative-timeout=SECONDS Set negative timeout to SECONDS in fuse kernel module (the default is 0). --volfile-check Enable strict volume file checking. Miscellaneous Options -?, --help Display this help. --usage Display a short usage message. -V, --version Print the program version. FILES
/var/lib/glusterd/vols/*/*.vol EXAMPLES
mount a volume named foo on server bar with log level DEBUG on mount point /mnt/foo # glusterfs --log-level=DEBUG --volfile-id=foo --volfile-server=bar /mnt/foo SEE ALSO
fusermount(1), mount.glusterfs(8), gluster(8) COPYRIGHT
Copyright(c) 2006-2011 Red Hat, Inc. <http://www.redhat.com> 07 March 2011 Clustered File System GlusterFS(8)
All times are GMT -4. The time now is 10:13 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy