Hi, everyone,
I want to ask a question about the tomcat and the Linux terminal. I have a jsp file and a tomcat server. After I use the terminal to login in my Linux computer, I want to put the file to the tomcat server. However, I don't know the cmd of this action. Does anyone can help me?
P.S can also provide some basic cmd for the Li...
hi,
I has a Library impelmented based on Python's telnetlib.
And recently, i noticed that the performance in windows xp and Linux is so different.
below script, i design three operations, "get units", "just press enter", "get units with options"
"get units" has long string return, "get units with options" return shorter string, and "j...
I have bash script that I use regularly in my job to automate a large job. I was making some changes today, but everything seemed fine. The script itself is about 1700 lines long. The first part of the script is all good and runs through all the user input and logic just fine. It then proceeds into the core of the script and stops wo...
We can use printk to send debug message in kernal driver. I have a user mode AP that call kernal driver. I would like to output user mode AP debug message with kernal mode driver at the same time. How to do that?
...
Hi,
is there a way to check programmatically (via ioctl(), etc.) or by reading a file in /sys, /proc or /dev) whether the screen has been blanked by the Linux console screensaver?
Thanks and best regards,
Günter
...
I wrote a sh program which when you type in the argument which is a file name of an image the program would preview it and this can take multiple arguments (as show below)
#!/bin/sh
for i in $*; do if [ ! -f "$i" ]; then
echo "invalid file $i"
else
display -size 40x50 $i &
fi
done
How would i be able to limit the ...
Hello,
I need to copy data from one database into my own database, because i want to run it as a daily cronjob i prefer to have it in bash. I also need to store the values in variables so i can run various checks/validations on the values. This is what i got so far:
echo "SELECT * FROM table WHERE value='ABC' AND value2 IS NULL ORDER B...
i have lots of videos in my server and i use the following code to get the duration of the video and it works fine..
ob_start();
passthru("ffmpeg -i ".$srcfile." 2>&1");
$duration = ob_get_contents();
ob_end_clean();
But i could not get the duration for the files which has a space or any special charac...
There are some Linux based C++ projects in the pipe. What IDEs should I go for that have some kind of "intellisense" in par with, or better, than the one of a bare Visual Studio (that is, without the Visual Assist steroids).
(Note that I didn't use the words "as good as, or better". I consider the Visual Studio C++ intellisense everythi...
If I want to create a *nix symlink, I'll call symlink();, if i'm running a script on windows and I want to create a shortcut, I'd use Win32::Shortcut.
But what if I want to create a Windows shortcut if running a script from a *nix machine?
I'm accessing a SMB share on a Windows Server 2003 machine from my *nix machine.
...
hi, all, I have a python test script to test and launch several subprocesses and after some interval of time, terminate these subprocesses. e.g.
[username@machine workdir]python call_test.py
and inside one test case of this call_test.py, it is bit like this.
def test_launch_kill(self):
p1 = subprocess.Popen("./exec1")
thread...
Hi
i am new to linux platform and now i wanted to remove write permissions of all the php files under my root folder. It would be appreciable if somebody can suggest a solution.
thanks and regards
tismon
...
I am looking for a browser class that can be created in a terminal program in g++ that will create a page in memory and execute client JavaScript.
environment is Linux, server is h ubuntu 10.04 there is no GUI installed, program would be an occasional cron script.
is there such an animal?
edit: removed vbscript
...
Hi
I have 2 static linux libraries, created by ar cr, libabc.a and libxyz.a.
I want to merge them into one static library libaz.a.
How can I do this.
I want to create a merged static library, not to give both libraries to final link of applications
...
Hi, I am trying to understand interrupts and am looking for a simple code that uses interrupts. Could somebody please help me with it?
...
I am trying to change my uid to 0 as non-root with the CAP_SETUID capability. I have the following program:
#include <sys/types.h>
#include <unistd.h>
#include <stdio.h>
#include <sys/capability.h>
#include <sys/prctl.h>
int main(int argc, char *argv[])
{
printf("cap setuid in bset: %d\n", prctl(PR_CAPBSET_READ, CAP_SETUID, 0, 0, 0...
I am a noob in shell-scripting. I want to print a message and exit my script if a command fails. I've tried :
my_command && (echo 'my_command failed; exit)
but it does not work. It keeps executing the instructions following this line in the script. I'm using Ubuntu and bash.
Thanks all.
...
I use pthread_create to create several child threads. At a time, the main thread wants to kill all child threads or there will be segment falut. Which function should I use to finish that? I searched the answer from google and got function like pthread_kill. But I did not know which signal should I send to the child thread to kill them. ...
The following command, run either from cron or the prompt, does not make the expected log. I expect to get a log with the date as the file name. I am able to do this in Windows by using %date% and it makes the date the filename. What am I doing wrong here.
/root/backup_scripts/new_scripts/test.sh>/root/backup_scripts/new_scripts/$date.l...
I've been tinkering with GlassFish 2.1.1 lately, on both an Unbuntu Linux box as well as a Windows XP one.
Looking at the "java" processes representing asadmin, JavaDB server, and the GlassFish app server domain itself on Windows (using the Task Manager), they add up to just over 100 MB of memory.
However, looking at the same proce...