General :: Printing To A Progress Bar To The Terminal From Java/C++ - Stack Overflow?
Sep 18, 2011
I want to update the percentage progress of my program on the screen. I have a progress bar that I print. I add a * when the progress is more than 10%, but I also want to write the actual percentage correct up to every digit. However, I do not want to write a new number every time, since it will have the following effect:
1
2
3
4
Instead, I would like to just maintain one single figure on the screen that keeps getting updated. How do I do that? (... in Java/C++, but I think it's irrelevant)
View 2 Replies
ADVERTISEMENT
Sep 22, 2010
I'm working with some basic stack overflows. The following code compiles & runs fine in a non-ubuntu VM that's has no security features installed. On Ubuntu 10.04 it segfaults every time. I'm compiling on Ubuntu with the gcc -fno-stack-protector flag. If someone could point me to the security feature that's causing the segfaults (and how to disable it),
[Code]...
View 1 Replies
View Related
Mar 21, 2011
I'm SSHing to a headless Ubuntu box and sometimes need to upload files from that box via FTP. The built-in FTP client does not show the progress of my upload (or at least I don't know how to view it). I just see this during the operation (which could take up to an hour):150 Opening BINARY mode dataonnection for MyFileAre there any FTP clients which I could use in terminal and would show the progress (some kind of a progress bar or just the percentage)?
View 2 Replies
View Related
Aug 19, 2010
I am new both here and in Linux. As the subject says, I would like to learn how to copy a directory (not a file) from terminal with progress bar showing. The copy is local, i.e., not to another computer. My distro is CentOS 5.5. I know that if I do it with nautilus I would see the progress, but I want to learn how to do it from the terminal. I know that PV command can show a progress bar, but from what I saw, it works well for files, but not for directories (recursive).
Is it possible to use PV for directories? If yes, could you please show me the syntax? I also saw that some people mentioned that rsync can also show a progress bar, I tried to do it, but it didn't work out - perhaps I got the syntax wrong. If rsync can really be used to copy directories with progress bar, show me the syntax? Any other ideas on how to do it? I would like ideas that do not involve using any script, i.e., just something that I can do using the regular commands.
View 6 Replies
View Related
Mar 9, 2009
After searching I cant find script that can deal with directories. All the found scripts work file to file and not directory to directory. Someone know script that can deal with all this situation?
View 8 Replies
View Related
Nov 21, 2010
I'm looking for a terminal emulator that does the same thing as gnome-terminal or konsole, except written in Java.
View 2 Replies
View Related
Apr 28, 2011
I have a small java project that handle connections. In order to run it from the terminal I have to cd into the folder that contains the source and run the following command:
java -cp classes com.packagename.mainclass
Where classes is the folder that contains the classes. I want ubuntu to run this application on startup, is there a Java command I can use? Or am I just better off creating a shell script?
View 1 Replies
View Related
Sep 12, 2010
Is it possible to run a java command as soon as the terminal opens and after it displays you have the normal terminal prompt. I have an ascii header i made its a java file and i want it to display every time i open the terminal so it shows as a header.
View 1 Replies
View Related
May 21, 2010
I have set up an HP 5M networked printer. The test page works fine, and the defaults are all set correctly. But when I try to print from my own java programs, the paper size is set to letter, and the margins are all set to 2.54 mm. I can change the paper size to A4 (but I have to do it EVERY time). And the margins won't even let me change them. I type in 0, click in the next field, and the value changes straight back to 2.54. It has been this way for at least the last two releases of Ubuntu.
View 4 Replies
View Related
Jan 28, 2010
Our Company is using a ERP solution in linux platform, now we are facing a problem with remote printing Linux to Linux, Linux to windows and windows to linux
I have an EPSON LX1050 printer setup via parallel port in linux machine .Recently we purchased RTextPrinter driver (Text mode printing for the Java platform)
I can print java app via Linux Local system, windows local system and windows to windows .But Network printing isn't working
The following the java class path of local and network printer setup
Local printing code : it's working
Note: /dev/lp0 Linux local printer
Remote Pronting code: not working
Showinf error:
They are providing one example code is:
This is a very simple example:
Command set
View 2 Replies
View Related
Jan 6, 2011
Every now and then on my non-graphical console-orientated Debian Squeeze system, some services see it fit to spill their juices all over what I am doing.
A message about a service stopping/starting/restarting prints at the location of my cursor ontop of whatever I was doing at that moment, forcing me to either redraw ( if the currently running application supports it ), background and then foreground what I'm doing or clear the screen if at the shell.
Code:
* Restarting OpenBSD Secure Shell server sshd
* Restarting advanced system logger rsyslogd
How can I stop these messages appearing? Even better would be to send them to /dev/tty8 where I've configured rsyslogd to write.
View 2 Replies
View Related
Jul 26, 2010
I've just installed java (jre-6u21-linux-i586.bin) on Red Hat 4.4 AS and issued this command to check the java version: java -versionand got :bash :java: command not found
View 4 Replies
View Related
May 19, 2010
would like to install a Bluetooth and my AT&T 3g fob
View 1 Replies
View Related
Apr 17, 2011
Can anyone tell me that how to get information about stack, allocated by kernel to a running process? for this ,is there any api function,any system call is available in ubuntu 8.04 ?
View 2 Replies
View Related
Jul 20, 2011
I need to increase the default stack size on Linux. As I know there are usually two ways:
ulimit -s size
/etc/security/limits.conf
The ulimit method only works as long as I am logged in.
limits.conf will work after a restart.
Is there a possible way to increase the limit without restarting?
View 2 Replies
View Related
Jan 21, 2011
I am trying to install the Sun Microsystems Java Runtime on my Ubuntu Server 10.10, but it is telling me that it is not available. I have researched online and it tells me that it is a part of the multiverse repository. I have not had very much success in activating this either.
View 1 Replies
View Related
Feb 16, 2011
I am running Ubuntu 10.10, and I am trying to run a java process in the background of a terminal, so I can continue to use that terminal.
Other applications will run in the background just fine, but when I run my java application, I cannot change the status of the process from "Stopped" after suspending it.
Here is my command syntax, along with some commands I have tried and their outputs:
There were [1]- entries, but I removed them for simplicity.
View 4 Replies
View Related
Feb 20, 2011
First you'll want to remove the old JRE or openJDK (if you have it). When JRE is installed from the repositories, do it like this: System - Administration - Synaptic Package Manager
Query: sun java Tick all installed packages and choose complete removal. When it's installed manually in /opt/java, see the instruction at the bottom of this column (under the header Removal). If you don't have JRE, then you'll probably have openJDK. That one should be completely removed as well. That can also be done with Synaptic Package Manager (query: openjdk).
[Code]...
View 1 Replies
View Related
Nov 5, 2009
I have this command in a bash script
Code:
!#/bin/sh
cd /home/n3t
tar -czf /media/disk/BACKUP/home/Pictures/$BACKUPDATE.tar.gz ./Pictures
How can I create a progress bar for this action? I have download the clpbar but I don't know how to use it exactly.
View 1 Replies
View Related
Nov 9, 2009
I want to create a script which will show the amount of data that is been copied from one location to another location. For example: Say I have a file called abc.img which is approximately 4 gb of size therefore every time I copy the file from one location to another I want a progress bar to appear like 50% completed 51% completed and so on.
View 2 Replies
View Related
Jan 19, 2010
Java is installed in linux machine and when I enter the command java -version it shows java is not found.At the same time when i run from the folder where its installed with ./java -version it works.
first of all why its not working from any other place? also why do I need to give ./ from the folder?
View 3 Replies
View Related
Jan 29, 2010
Do Windows XP, Vista, Windows 7 and all Linux distributions have Java JRE installed so end-users don't have to install it to run Java applications?
View 4 Replies
View Related
Jan 26, 2010
I have to give it up for the Ubuntu developers. It is nearly impossible to exploit a simple stack overflow. I'm studying overflows for a project so I need it to work. I set /proc/sys/kernel/randomize_va_space to 0 and when I compiled my program I used -mpreferred-stack-boundary=2 and -fno-stack-protector. But for some reason no matter how much input I enter it won't overwrite the EIP. What is stopping this from working that other linux versions don't have? And does anyone know of a way to bypass it?
View 1 Replies
View Related
Jan 17, 2010
I run a program by executing this command in a terminal screen.Code:coco@coco-desktop:~/Escritorio/MO_1.10/MagnumOpus$ java -jar MagnumOpus.jarSince it is a bit tedious, I tried to create a launcher. I copied the above code into the Command box. The launcher is created, but fails to run the program. Instead I get an error message.
View 6 Replies
View Related
Nov 14, 2010
Can't get an applet to initiate on a gaming site...is their a simple terminal command to install the latest version of Java?
View 9 Replies
View Related
Sep 23, 2010
I can get some sort of indication to show a shell script is running? Even a simple rotating cursor will do, or an increasing row of dots.
Here's one of my scripts...
#!/bin/sh
echo "Main directories"
echo ""
cd /home
[Code]....
View 9 Replies
View Related
Jan 20, 2010
I have a Shuttle XPC with 3 drives. /dev/sda is a 320GB SATA drive with a basic installation. Two partitions, a swap and the rest is on /. The other two drives are 1.5TB SATA configured as a software mirror as /dev/md0.
I want to use dd to clone the 320GB boot/OS drive to a 750GB SATA I have at home. Last night I put the 750 in a USB enclosure and at about 6:00 PM fired off: dd if=/dev/sda of=/dev/sdd
It's now 7:16 AM and the dd is *STILL* going. Is this unusually long to clone the drive? Is there any way to check the progress or a way to launch dd with a progress indicator?
View 3 Replies
View Related
Oct 15, 2009
I would like to start learning about the nuts and bolts concerning Linux security. I bought the "Gray Hat Hacking" book by Harris et al. and started working at their example for buffer overflows but hit a bump immediately. Is this the right place to be discussing this sort of thing? If so I give pertinent info below:
Program:
//overflow.c
#include <string.h>
main(){
char str1[10]; //declare a 10 byte string
[Code].....
View 2 Replies
View Related
Jun 8, 2010
However, every time snmptrapd gets a snmp notification, it aborts. In debug mode, it reports a buffer overflow detected. I've tried another core 13 and a core 12, with net-snmp 5.5. On these three systems, snmptrapd behaves the same. Here is my snmptrapd.conf,
disableAuthorization yes traphandle default touch /root/a.txt I triggered snmptrapd with, snmptrap -Ci -v 2c -c public localhost "" "1.3.6.1.4.1.8837.4.1.2.1.2.1.6.4" 1.3.6.1.4.1.8837.4.1.2.1.2.1.6.4 int 500 Same result I got with my firewall snmp traps. Some other different scripts replaced in traphandle default, got the same. A small portion of debug info listed,
[Code]...
View 2 Replies
View Related
Dec 31, 2010
Did Walnut Creek overflow its banks and swallow up theSlackware.com Domain name??Pat Volkerding Danger
View 3 Replies
View Related