Sponsored Content
Top Forums Shell Programming and Scripting Grepping for hex characters - explanation? Post 302491366 by mregine on Thursday 27th of January 2011 08:44:28 AM
Old 01-27-2011
Thanks to both of you. I've learned something and I even know where to look for more :-)
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

grepping the first 3 characters from a file

Hi I was wondering if it's possible to use a command to get the first 3 characters of a line in a text file, I tried grep but it returns the whole line but I am only interested in the first 3 characters. Is this possible with grep or I need any other command? Also is it possible deleting from... (2 Replies)
Discussion started by: g-e-n-o
2 Replies

2. UNIX for Dummies Questions & Answers

grepping the first 3 characters from a file

give this a try and let me know if it works grep '^' filename rachael (2 Replies)
Discussion started by: rachael
2 Replies

3. Shell Programming and Scripting

Replacing all but last Hex characters in a text line

I must remove hex characters 0A and 0D from several fields within an MS Access Table. Since I don't think it can be done in Access, I am trying here. I am exporting a Table from Access (must be fixed length fields, I think, for my idea to work here) into a text format. I then want to run a... (2 Replies)
Discussion started by: BAH
2 Replies

4. HP-UX

Hex characters of ascii file

Hi, Whats the command or how do you display the hexadecimal characters of an ascii file. thanks Bud (2 Replies)
Discussion started by: budrito
2 Replies

5. Shell Programming and Scripting

Grepping characters

Hi friends, I want your help. I have a flat file. I want a script to search following pattern in it and once it get that pattern it should grep next 7 characters from it and should keep it in output file output.TXT Pattern is RSTD3R0******* In above example, characters in the place of *... (3 Replies)
Discussion started by: anushree.a
3 Replies

6. Programming

After converting the hexstr to Hex and storing the Hex in a char*

Hi All, My main intension of is to convert the Hexstring stored in a char* into hex and then prefixing it with "0x" and suffix it with ',' This has to be done for all the hexstring char* is NULL. Store the result prefixed with "0x" and suffixed with ',' in another char* and pass it to... (1 Reply)
Discussion started by: rvan
1 Replies

7. Shell Programming and Scripting

Replacing hex characters '\x0D' with '\x0D\x0A'

Hello All, I have a requirement where I need to replaced the hex character - '\x0D' with 2 hex characters - 'x0D' & 'x0A' I am trying to use SED - But somehow its not working. Any pointers? Also the hex character '\x0D' can occur anywhere in the line. Can this also be accomplished... (6 Replies)
Discussion started by: paragkalra
6 Replies

8. Shell Programming and Scripting

Convert hex values to displayable characters

Hi, I am a bit stuck with displaying characters. I am having values like below in the proper displayable characters. which I would want to print the actual value on the right hand side. I dont want to create an array because I would have to create 255 different values. isnt there another way of... (17 Replies)
Discussion started by: ahmedwaseem2000
17 Replies

9. UNIX for Dummies Questions & Answers

Replacing hex characters

I have the following file consisting of dates and sample measurements: 05��Oct��2010 1.31�� 06��Oct��2010 1.32�� 07��Oct��2010 1.31�� The hex characters are \xc2\xa0 in sequence. I have tried to remove the characters as follows: sed -i '' -e 's/\xc2\xa0//g' file.dat and as follows... (6 Replies)
Discussion started by: figaro
6 Replies

10. HP-UX

Replacing Hex Characters In A File Using awk?

Hi guys, First off, i'm a complete noob to UNIX and LINUX so apologies if I don't understand the basics! I have a file which contains a hex value of '0D' at the end of each line when I look at it in a hex viewer. I need to change it so it contains a hex value of '0D0A0A' I thought... (10 Replies)
Discussion started by: AndyBSG
10 Replies
LATCP(8)						      System Manager's Manual							  LATCP(8)

NAME
latcp - LAT Control Program SYNOPSIS
latcp [options] DESCRIPTION
latcp is the control program for latd(8). OPTIONS -s Start the LAT daemon. This is the only way to start LAT, you should not attempt to run latd directly or you may get unexpected behviour. latcp -s runs the file /etc/latd.conf as a shell script (using /bin/sh). Any customisations you need to do to the LAT system should be put in this file as latcp commands. The latcp command should be invoked using the environment variable $LATCP. An example latd.conf file is shipped with the package and shown in the man page latd.conf(5). latcp -s passes any extra switches onto latd itself so you can customise latd this way, however latd.conf is recommended. -h Halts latd. This will kill any active sessions without warning. -A Create a local LAT service or reverse LAT port. The syntax for creating a login service is: latcp -A -a service [-i description] [-r rating] [-s] [-C command] [-u user] The -s flag indicates that the service rating is static. Without this the service rating is regarded as a maximum and will be reduced according the the load average of the machine. The -C flag indicates a command to run when a user connects to the service - by default this is /bin/login. The -u flag specifies a user to run the above command as. By default this will be root. The syntax for creating a reverse LAT port is: latcp -A -p tty -V learned_service [-R rem_port] [-H rem_node] [-Q] [-8] The tty name should start /dev/lat and must not exist. The -Q flag indicates that connections to the service is queued. If you con- nect to a queued service and it is busy then your connection will be forced to wait until it is available. You must use this flag for printer services on DECserver 90L terminal servers, and in this case the service name must also be empty. NOTE that the -Q flag is the opposite way round to that on Tru64 Unix(r). The -8 flag tells latd not to muck about with the data. Normally latd will transmit a BREAK if a NUL character is typed, -8 disables this behaviour for ports with (eg) printers or modems attached. -D Delete a service or port. latcp -D -a <service> deletes an advertised service created with latcp -A -a. latcp -D -p <tty> deletes a reverse LAT port created with latcp -A -p -i Change the description of an advertised service latcp -i <description> -a <service> If the description contains spaces or shell metacharacters you should enclose it in quotes. -j Enables the service responder. This feature is needed for small terminal servers that do not collect their own service lists. I currently don't have a list of servers that need this feature. can anyone help?? -J Disables service responder. -Y Purges the list of known services from latd's internal tables. -x Change the rating of an advertised service latcp -x <rating> [-s] -a <service> If the -s flag is present the rating is static, otherwise it is treated as the maximum value and will be decreased according to the system load average. -n Change the system's current node name (Note this affects latd only, not DECnet nor TCP/IP) latcp -n <nodename> -r Change the retransmit limit. This is the maximum number of times latd will transmit a packet without an acknowlegement. If this num- ber is exceeded then the connection is closed as it is assumed that the remote end has gone away. This value must be between 4 and 120 inclusive, the default is 20. -m Sets the multicast timer (in seconds). This timer determines how often services are advertised on the LAN. The default is 60 sec- onds. This value must be between 10 and 180 inclusive. -k Sets the keepalive timer (in seconds). This is the maximum amount of time that a connection can be inactive. When this timer expires an empty message is sent to the remote end. If it does not respond after <retransmit limit> then the connection is closed. This timer is reset every time a packet is sent out. This value must be between 10 and 180 inclusive. -d Displays latd configuration or the learned service table. -d on it's own will display the latd configuration and the services that are advertised by this node. -d -l will display the learned service table. Adding -v will show the learned service table in a ver- bose manner. -n will show the nodes (with MAC addresses) that are associated with serviceless ports (eg reverse LAT ports to DS90L+ servers). -? Displays help for using the command. -G Add groups to the services advertised. The groups can be numbers seperated by commas or a range. eg latcp -G 1,2,3,10-20 Enables groups 1 2 3 and 10 to 20 inclusive. -g Disable groups using syntax as above. -U Add to the list of groups that the server will accept when listening for services. this affects the services that are available using the "reverse LAT" feature. See -G for the syntax. If you are using the "responder" feature it's best make sure that this group list contains all the groups that are likely to be used on the LAN. -u Remove groups from the user groups list. SEE ALSO latd(8), latd.conf(5), moprc(8), llogin(1) LAT Server September 10 2002 LATCP(8)
All times are GMT -4. The time now is 12:36 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy