| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
We ran into an issue where qarsh would wait for 3 seconds
after a command ran. This was traced back to the select()
in handle_qarsh() being restarted when SIGCHLD was received.
I moved the waitpid() to just before the select() and turned off
the signal restart. This closes those timing windows and allows
qarshd to quickly finish after the child exits.
|
|
|
|
| |
This was hitting easily on RHEL5 systems
|
|
|
|
|
| |
Instead of moving the setup for SIGCHLD handling, I'm removing it.
waitpid() isn't that expensive and we know the pid we are waiting for.
|
| |
|
| |
|
|
|
|
|
| |
We really don't need this field since we
always copy data sequentially.
|
| |
|
|
|
|
|
|
|
|
|
| |
This change breaks the qacp protocol!
Before there was a chance we would exit before receiving and checking
all packets from qarshd. Now we look at all packets and check them.
Use data allow packets and larger buffers.
Handle errors on the write end.
|
|
|
|
|
|
|
| |
If xiogen is flooding requests across qarsh and
xdoio decides to stop, we need to handle that gracefully.
Also, making the pipe non-blocking was not a good idea, xdoio
gets the read error EAGAIN and stops there.
|
| |
|
|
|
|
|
|
|
| |
When qarshd is run via xinetd, stderr still goes out the socket
and messages from sockutil.c or qarsh_packet.c can interfere
with the protocol. Create a thin wrapper which qacp and qarsh can
send to stderr and qarshd can send to syslog.
|
| |
|
|
|
|
|
|
|
|
|
| |
This coordinates the buffer sizes with the
max packet size. qarshd and qarsh will probably break
if this value does not match between client and server
builds. Also increase the value to reduce overhead.
A max packet size of 16k only yields 40MB/s. Increase
that to 128k and we can do 500MB/s.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Only handle one file transfer at a time so we don't need
an array to track multiple transfers or know the remote's
fd number.
Loop in recv_packet until we read a whole packet.
|
|
|
|
| |
Added a new packet to limit data sent from the other side.
|
|
|
|
|
|
| |
This allows us to attach gdb before anything
interesting happens. Use the command
'signal 14' to get the process running again.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
I removed the buffering layer from recv_packet because
it made the logic too complex around the pselect in qarshd.
Now only read as much as needed to get each packet.
qarshd adds an array for remote file descriptors which is
only a stub for now. This needs to be expanded to allow
multiple file transfers at the same time for runcmd.
|
|
|
|
| |
This should get sent to the journal or syslog
|
| |
|
| |
|
|
|
|
| |
This is mostly for clarity while debugging qarshd.
|
|
|
|
|
|
| |
Cache the results from the rstat packet and use that file size
during the following sendfile so we don't send more than qacp
is expecting. This should allow us to qacp root@host:/var/log/messages
|
| |
|
|
|
|
| |
For those that can't configure syslog properly while debugging other things.
|
|
|
|
| |
but lets you in. Don't bother checking the return of chdir().
|
| |
|
|
|
|
|
|
|
|
| |
ugly warnings. We should always be compiling with 64-bit off_t's so
this should not be a problem.
Change nread and nwrote back to ssize_t's since that is what read and write
return. nleft remains an off_t because we initialize to stat.st_size.
|
|
|
|
|
|
| |
I changed all formats from %zd to %lld, but this adds a lot of warnings
because off_t isn't the same as long long int to the compiler. I don't
know if there is a way to avoid the warnings on all platforms.
|
| |
|
| |
|
| |
|
|
|