I don't know how to ask this clearly, so I'll try my best...
At what point does a shell script stop reading from a file, and begin using the buffered script?
Hopefully, this example will shed some light:
Now, if I execute this in the background, it will just wait for me.
During that time, if I edit tmp.sh, and uncomment the "Value Please" line, and comment out the "What is your value" line, it will continue with "What is your value".
If I comment out the "echo Lo" line, before I type "quit", the change is effective when the script completes.
As I understand it, the shells reads the loop into memory, and loops away... It doesn't seem to read the rest of the script in until I get to that part of the script...
Is there some documentation on this (as far as which circumstances will cause the shell to read ahead or not)?
I can provide other examples, if this one makes no sense (well, as much as it could, considering the silliness of a self-rewriting script, or the dangerous nature of modifying a script that is currently running....)
I am looking for C program source code. Could you please help me in finding the source code required mentioned below.
program to create multiple threads (one master thread and rest worker threads) and using the threads write into and read from shared memory
Restrictions:
Only one thread... (2 Replies)
Hallo,
i need a Prompting read in my script:
read -p "Enter your command: " command
But i always get this Error:
-p: is not an identifier
When I run these in c-shell i get this error
/usr/bin/read: read: bad option(s)
How can I use a Prompt in the read command? (9 Replies)
I created a shared memory and attached it. I also created the appropriate semaphores to sync. my read/write operations. However I do not know how am I supposed to do so. Anyone has got any ideas? I want to write int the form of 1234:23:444:... where each number between : means something to the... (0 Replies)
I have created and attached a shared memory segment. However I do not know how am I supposed to write and read data from it. I want to save various different data on this segment such as process IDs and other. Do you know how am I supposed to write these and be able to read such data in the correct... (1 Reply)
Hi everyone. I asked once here and it went well, so I'm very happy with this community.
I have a new question to ask. I would like to read&write specify memory of a process which is not the process I'm doing it from, nor a child nor a parent.
So, I want to do a program similar to Cheat... (3 Replies)
Hi!
Does someone know how to ensure that root user always will be able to login to a system?
What I mean is when a server is out of RAM and swapping like hell; sshd may spawn a shell and login root user to save the day? (2 Replies)
Dear,
How to calculate %computational memory and %non computational memory from AIX server.
What command used to find out %computational memory and % non computational memory except topas.
Regards
Nowshath (1 Reply)
So I am pretty new to the linux environment, and I am trying to create a shell that uses multiple pipes, and I read online that piping using shared memory space is more efficient than using regular piping. However, I have zero clue how to use shared memory space with pipes. Has anyone done this... (1 Reply)