Sponsored Content
Top Forums Shell Programming and Scripting how to let "this" find all hard drives correctly Post 302348101 by rs6000er on Thursday 27th of August 2009 10:09:21 AM
Old 08-27-2009
how to let "this" find all hard drives correctly

hi all

I've been working on a project to create a custom centos live-cd with a tsm client installed.

so far, the kickstart script isnt working properly to add icons into a live user's desktop.

I found there is a expression looking strange. it isnt working, neither.

HARD_DISKS=\\\`egrep "[sh]d.\\\$" /proc/partitions | tr -s ' ' | sed 's/^ *//' | cut -d' ' -f4\\\`
cut: invalid byte, character or field list
Try `cut --help' for more information.
-bash: [sh]d.\$: command not found

please advice.

thanks in advances,

Frank
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

grep to find content in between curly braces, "{" and "},"

problem String ~~~~~~~~~~~~~~~~~~ icecream= { smart peopleLink "good" LC "happy" , smartpeopleLink "dull" LC "sad" } aend = {smart vc4 eatr kalu} output needed ~~~~~~~~~~~~~~~~~~ smart peopleLink "good" LC "happy" , smartpeopleLink "dull" LC "sad" smart vc4... (4 Replies)
Discussion started by: keshav_rk
4 Replies

2. Shell Programming and Scripting

"find command" to find the files in the current directories but not in the "subdir"

Dear friends, please tell me how to find the files which are existing in the current directory, but it sholud not search in the sub directories.. it is like this, current directory contains file1, file2, file3, dir1, dir2 and dir1 conatins file4, file5 and dir2 contains file6,... (9 Replies)
Discussion started by: swamymns
9 Replies

3. Red Hat

"No Drives Found" error during Redhat Linux AS 4 installation

I'm trying to install Redhat LInux AS 4 update 4 on an IBM x306 series server. I keep getting following error: "No Drives Found. An error has occurred - no valid devices were found on which to create new file systems. Please check your hardware for the cause of this problem." I called IBM and... (2 Replies)
Discussion started by: pieman8080
2 Replies

4. Ubuntu

where to find the message "Your disk drives are being checked for errors"

Hi, During start up I got the message "Your disk drives are being checked for errors". But it went so fast that I could read following messages. Once logged I though I could find it in "dmesg" but nothing... May someone know where I can find plese ? :) (3 Replies)
Discussion started by: xib.be
3 Replies

5. Shell Programming and Scripting

awk command to replace ";" with "|" and ""|" at diferent places in line of file

Hi, I have line in input file as below: 3G_CENTRAL;INDONESIA_(M)_TELKOMSEL;SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL My expected output for line in the file must be : "1-Radon1-cMOC_deg"|"LDIndex"|"3G_CENTRAL|INDONESIA_(M)_TELKOMSEL"|LAST|"SPECIAL_WORLD_GRP_7_FA_2_TELKOMSEL" Can someone... (7 Replies)
Discussion started by: shis100
7 Replies

6. Shell Programming and Scripting

Using sed to find text between a "string " and character ","

Hello everyone Sorry I have to add another sed question. I am searching a log file and need only the first 2 occurances of text which comes after (note the space) "string " and before a ",". I have tried sed -n 's/.*string \(*\),.*/\1/p' filewith some, but limited success. This gives out all... (10 Replies)
Discussion started by: haggismn
10 Replies

7. Shell Programming and Scripting

Find lines with "A" then change "E" to "X" same line

I have a bunch of random character lines like ABCEDFG. I want to find all lines with "A" and then change any "E" to "X" in the same line. ALL lines with "A" will have an "X" somewhere in it. I have tried sed awk and vi editor. I get close, not quite there. I know someone has already solved this... (10 Replies)
Discussion started by: nightwatchrenba
10 Replies

8. Shell Programming and Scripting

How to find a file which are not ends with ".zip" and which are ends with "*.log*" or "*.out*"?

I am new to bash/shell scripting. I want to find all the files in directory and subdirectories, which are not ends with “.zip” and which are contains in the file name “*.log*” or “*.out*”. I know below command to get the files which ends with “.log”; but I need which are not ends with this... (4 Replies)
Discussion started by: Mallikgm
4 Replies

9. Shell Programming and Scripting

find . -path "*_nobackup*" -prune -iname "*.PDF" \( ! -name "*_nobackup.*" \)

These three finds worked as expected: $ find . -iname "*.PDF" $ find . -iname "*.PDF" \( ! -name "*_nobackup.*" \) $ find . -path "*_nobackup*" -prune -iname "*.PDF" They all returned the match: ./folder/file.pdf :b: This find returned no matches: $ find . -path "*_nobackup*" -prune... (3 Replies)
Discussion started by: wolfv
3 Replies

10. Shell Programming and Scripting

Bash script - Print an ascii file using specific font "Latin Modern Mono 12" "regular" "9"

Hello. System : opensuse leap 42.3 I have a bash script that build a text file. I would like the last command doing : print_cmd -o page-left=43 -o page-right=22 -o page-top=28 -o page-bottom=43 -o font=LatinModernMono12:regular:9 some_file.txt where : print_cmd ::= some printing... (1 Reply)
Discussion started by: jcdole
1 Replies
SYSTEM-CONFIG-KICKSTART(8)				      Kickstart Configurator					SYSTEM-CONFIG-KICKSTART(8)

NAME
system-config-kickstart - graphical interface for creating kickstart files SYNOPSIS
system-config-kickstart [KSFILE] DESCRIPTION
system-config-kickstart provides a simple method of creating a kickstart file that can be used to automate the installation process on Red Hat Enterprise Linux, Fedora, and derived distributions. If given, the program will take its initial settings from the KSFILE provided on the command line. This allows editing of existing kick- start files. Currently, this program has some serious limitations. For example, it cannot work with LVM nor do advanced RAID and BTRFS configurations. These are supported by kickstart, but the graphical program does not provide a way to set them up nor manipulate them in existing kickstart files. OPTIONS
--help Print out program usage. --generate FILENAME Examine the system and create a kickstart file that more or less matches, writing the output to FILENAME. --display DISPLAY# Specify the X display to use. EXAMPLES
To run the program type: system-config-kickstart REPORTING BUGS
Report bugs to <http://bugzilla.redhat.com>. AUTHORS
Chris Lumens <clumens@redhat.com> Brent Fox <bfox@redhat.com> Tammy Fox <tfox@redhat.com> Linux Fri 26 June 2013 SYSTEM-CONFIG-KICKSTART(8)
All times are GMT -4. The time now is 04:53 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy