Monday, May 24, 2010

How do I communicate over serial with an ARM processor in C?

I'm using a TS7200 found at: http://www.embeddedarm.com/epc/ts7200-sp...





All I've ever done with C is software, no hardware interfacing. I'll be communicating to a Garmin 301 Geko GPS on com port 1 in linux. All it has to do is to read data, not transmit.





I know that I wont get exactly what I need, but I can't find much on the internet to help me. Does anyone have a good site to look at?





Thanks for your help,


Brandon

How do I communicate over serial with an ARM processor in C?
I would go to a more experineced place on the internet then Yahoo! forum for C help. try developer fourms for linux only


Am trying to write java code to read n write bits at the parallel port of a computer.how can i do it on linux?

the motive is to be able to read and write bits at the parallel port using a JAVA application on a linux platform... i need to know how to get the permission ant control from the OS, i am able to do it in C using ioperm....

Am trying to write java code to read n write bits at the parallel port of a computer.how can i do it on linux?
Or may be you can contact a java expert. Check websites like http://getafreelnacer.com/
Reply:Mr. Rai try this link for PARALLEL PORT ADDRESSES








http://www.captain.at/parallel-port.php





IBM site





http://www.ibm.com/developerworks/java/j...





HOW TO CD-Writing





http://www.faqs.org/docs/Linux-HOWTO/CD-...

dracaena

Build a hierarchical tree, without using DOM,schema, and sax using expat parser and c?

I've been experimenting with the jclark's expat parser. I compiled it on linux, and it works just great. However, finding tags and data by implementing the callback functions in c language is cumbersome. Has anybody written code that uses the expat callback's in such a way as to build a hierarchical tree, without using DOM,schema, and sax, that can be traversed.My purpose, just enough to traverse branches and find leafs of a xml documents without using DOM, schema, and sax, and i also want help regarding how to convert a xml document to a hierachical tree which contains tags values. thanks

Build a hierarchical tree, without using DOM,schema, and sax using expat parser and c?
but what you're describing more or less is the same like a DOM, right? a hierarchical tree of xml data.





have a look at the link below, it's the Simple C Expat Wrapper which builds a DOM-like structure, maybe it can help you.


I am working on my first useful program in c! this is how far I got with it and I got stuck?

It is a calculator! And I am trying to make it give me a message when you input letters instead of numbers!








How would u write the whole program using functions????





this is the code! i use linux and the gcc compiler














#include %26lt;stdio.h%26gt;





int main( )


{


int z;


int x;





printf( "This is my first useful program ever created in C" );


printf( "\n" );


printf( "\n" );


printf( "Note that this calculator will subtract and divide the first integer by the second one" );


printf( "\n" );


printf( "\n" );





printf( "Input your first integer to be calculated:" );


scanf( "%d", %26amp;z);





printf( "Please input the second one:" );


scanf( "%d", %26amp;x);





printf ( "Added: %d \n", z + x );


printf ( "Subtracted: %d \n", z - x );


printf ( "Multiplied: %d \n", z * x );


printf ( "Divided: %d \n", z / x );


}

I am working on my first useful program in c! this is how far I got with it and I got stuck?
Two ways.





Check the return type. Look at http://www.cplusplus.com/reference/clibr... (scanf). It returns an int, which actually means something. Check if that integer matches EOF, and if it does, you know it failed to read in the input.





Only a beginner is excused from not checking for errors. Understand how the library functions work. If they set an error bit or return something on error, check for that.





The other way is to use fgets and strtol. Use fgets to take an input into a string. Then attempt to convert using strtol.
Reply:You will find lots of useful c programming sourcecode @ www.easytutor.2ya.com
Reply:Well, I'm not going to write the code for you--but one way you can figure out if inputs are characters or numbers, is to check its ascii code. If the ascii code of the input from the user is not that of a number, than return an error message.

morning glory

How to create our own library file and header file from c (OS is windows xp)?

I want to know how to create our own library file and header file in c.





i use turbo C and the os is windows xp.


i could find the command equivalent of 'ar' command in Linux (archieve command) same in Windowz xp





thanks

How to create our own library file and header file from c (OS is windows xp)?
hi,





first you can create header file by ( .h ) extension.for example triq.h in this file you can write what (functions) you wants in the header file.





second you can store this ( .h ) file extension in to header files location.





then crate c program and include this header file.thats all..bye
Reply:create files





bob.h


bob.c





In bob.c put:





#include "pathto\bob.h"





your c code here


Which is harder to learn Java or C++ ?

I would rate myself as a beginner/intermediate VB.NET programmer - very good at scripting with VBScript.





So I haven't really touched on either Java or C++ or any "real" programming since I personally consider VB.NET cheating as you're really just drawing and filling in the gaps with code you can search for online!!!!


Could someone recommend to me one or the other ? my destination platform would be both Linux and Windows.





Thanks in advance !!!!

Which is harder to learn Java or C++ ?
As far as object orientated programming goes, the fundamentals are very similar. I learned c++ first, and found it harder to learn that java. But that could have been because it was my first language.





What I am certain of though, is that java is much more sought after now than C++. So it may be more beneficial for you to learn that first.





As far as compilers go, for just starting off in object orientated programming, then you might want to go for a compiler called "bluej". It's a very simple GUI interface, to get you used to classes.





After that I would move on to netBeans IDE 6.0....and stick with it.
Reply:As long as you're comfortable with object orientated programming I think you'd find both languages about the same to learn.





In terms of jobs (if that's what you're thinking of), people seem to want Java programmers more than C++ programmers nowadays, and C# is an even better bet.
Reply:C++ is harder to learn, because most of the low level things found in C++ like pointers, garbage collection are handled automatically in java. Java programs can run on any platform that has a JVM (java virtual machine).
Reply:I'd say java because the polarity of the script certification does not interface with the trajectory of the triple mainframe processor.


Which is the best windows based c++ compiler?

I have been using g++ compiler that is available on linux. now I am switching to windows. And I want to do programming in the same way I used to do on g++. suggest me windows based c++ compiler that has this feature.

Which is the best windows based c++ compiler?
I have no experience in development on Linux platform.


To develop on Windows, i have used Microsoft Visual C++ (Most recommended for professional development).


Another recommended compiler is using the Borland C++ Builder.
Reply:Visual Studio seems to be the best on the windows platform. Borland's IDE was okay aswell, but i'm not sure if they still ship and or support it.


How do I practice C programming at home?

Hi,





I'm taking a basic programming class since I'm an electrical engineering undergrad. I have programming classes every Monday and Wednesday, however, for the type of learner that I am, I need to do a lot of practice. I asked my professor how I could work at home, but instead, he suggested that I just come into the lab to work my problems out. I live pretty far from school so I don't really want to do that. I mean, it's regular C language, so I'm positive I could do it on my laptop running XP media center '05.





I don't know the info you need to answer the question, but here are a few facts.





-We're using the OS Red Hat Linux


-We use text editor to program


-We use something called terminal that looks a lot like MS-DOS





I've read that I can use notepad and MS-DOS to do the same things, but I couldn't figure it out. I hope I gave enough info. I'll add on more if you do need to know some extra.

How do I practice C programming at home?
In linux


vi a.c


write code


type gcc a.c


run a.out


in windows


download turbo c compiler and use it to compile the code.
Reply:The Link below tells you how to write an ANSI C program using C++ in 2005 Visual Studio.
Reply:There will be some differences in the libraries available to a Windows Programmer and a Unix/Linux programmer. For example, Windows does not have a "fork()" function (as far as I know). Unix/Linux does not have a conio.h library.





I would suggest trying an install of Linux on your home computer as a dual boot system. While there are very good C/C++ compilers available for Windows, Unix/Linux is pretty much the standard for techies. If you're going into engineering, you will probably need to learn Unix in one form or another.





Also, Linux and Unix are pretty good about following standards. The Gnu compiler is pretty universal on all Unix like systems, like Linux and Mac OSX.





Any Linux distro will do. For a newbie, try using Ubuntu or Kubuntu. You will need to select development packages during the installation. You can use a fancy IDE like eclipse or Kdevelop. However I personally prefer to use EMACS while some folks I know prefer to use VI. In any case, these editors are geared more for programmers.





The Idea of using Notepad to edit code sounds excruciating. Notepad is not meant for programming. It doesn't have a C mode that automatically indents your code for readability. It doesn't have macros that make programming easier. It is simply a very bare bones editor.





Another option is to download the Cygwin toolkit. Cygwin is a port of the Gnu compiler for Windows and it includes a bunch of standard Unix libraries ported to Windows. It also includes a bash shell (the thing that's like the MSDOS prompt).





Learn the shell. Bash is much more powerful than the DOS shell and if you go into engineering and programming, you'll find it handy to know. I don't know how Windows programmers are able to program without it.





For an editor, I personally recommend EMACS. It has been ported to Windows. But for any really large projects, you'll want an IDE like eclipse.





Whatever you do, do NOT go out and buy Microsoft Visual C++ or C#. They are NOT standard and are not easily ported to Unix (where your schoolwork will be graded). As I said, as an engineer, Unix will probably be a requirement.
Reply:All you need to write C at home is a text editor and a compiler. The text editor can be as simple as notepad or as slick as the Eclipse integrated development environment. For a compiler, google 'c compiler' and you'll get a whole list of freebies.





Something else you might be interested in would be Microsoft's Visual C# (pronounced "C Sharp"). You can download Visual C# Express for free from their website, which will include a compiler and -- in my opinion -- the slickest of all integrated development environments, Microsoft Visual Studios 2008. From there, you can build Windows applications, web applications, XAML browser applications, web services -- all kinds of stuff.





Best of luck.








Edit -- to "Mike D"...





I find it hilarious that a professional programmer -- who uses EMACS, no less --can't figure out know how a Windows programmer can function without BAsh .





See, to me, one look at BAsh and emacs makes me have flashbacks from when I was programming Pascal on Unisys ICON machines in a QNX environment back in high school... Kinda makes me want to put a gun in my mouth, frankly.





I mean, say what you will about Microsoft, but Visual Studio sets the gold standard for integrated development. Open your mind, give it a tumble, and see what it's like writing code in the 21st century. You might just like it.

geranium

How do I read a BYTE [not a sector] from a CD, preferably in C++?

I do apologize for having to include this in my question, but because the programming section is usually plagued full of slackers, pranksters, embeciles, and just plain ignorant individuals that interfere with those of us that wish to use this sub-site as a learning tool, it must be included: Please READ the darn question before you answer it. Please give an INTELLIGENT answer, not Huh? wot? I dunno, etc. ... Please PAY attention Do not give me code for VB5 under WinNT, DJCPP, or GCC on Linux, when all you had to DO was READ the whole question to realize I do not want that particular information. Thank you all for letting me speak my piece. Now on to the rest of myt question. I can use code in VC6, Visual C++ 2005, and Visual C# 2005. Managed / .NET is acceptable as well. I can use code for any Win32 OS. However, I do NOT do VB6, VB.NET, .VBS, Linux or any code developed for a Non-Microsoft OS. Thanks for all the help.

How do I read a BYTE [not a sector] from a CD, preferably in C++?
Hmmm, I never tried that, but assuming the byte is in a known file, I would think you could just open the file (same as on your hard drive), and read it out as characters. You would most likely have to open it as read (not write or read/write). Thats what I would try first.
Reply:It really won't matter which language you use, you are probably going to have to do a lot of low level OS interfacing, because reading at that level potentially violates a lot of OS protections that have been put in place to keep random programs from reading and writing random bytes to random positions your IO devices. Its just like reading from the 1537614th byte from your NTFS filesystem... you're supposed to be interfacing with the filesystem at the conceptual filesystem level, not the byte level, and its a good thing that most programs cannot.





BTW, VB.NET is easily translated to C# so even if you had a VB.NET solution, you probably could find something that would automatically translate it to C#. But I really doubt you'd find either.





CD's, Hard disks, etc, all read in blocks of data at one time so, like G. Whilikers said, even if you read in one byte, at some place in your memory the CD reader has read in the whole 512 bytes... so if you have code to read in the sector, the're really no other way to do it. Just pick the specific byte you need from that sector block.
Reply:Either find a way to treat the disk as an i/o stream, or grit your teeth and read the sector then pick up the byte you want. Even if you had a getSpecificByteFromCD() function available, underneath it's going to be reading the whole sector behind your back anyway.


Best resource for learning C++ for a 15 year old?

I have learned the basics of Visual Basic, and PHP(Html/CSS Included) and little of Mysql.





Usually when I try and learn C++, I give up way to early because I never get to do the things I want to do. Write GUI, Media Apps, etc... I plan on developing for Linux with KDE.

Best resource for learning C++ for a 15 year old?
Try checking out your local book store for any books on it. Alot of times they will have a CD included with a compiler so you can run some test programs. Usually in the book they will have some example programs for you to build upon.
Reply:AP Computer Science
Reply:I know what to try.
Reply:Take a class.
Reply:See if they have C++ for Dummies at your library.
Reply:There are alot of resources out there. My favorite is http://www.planet-source-code.com


Why does the following C code give segmentation fault?

#include%26lt;stdio.h%26gt;


#include%26lt;string.h%26gt;


int main()


{


char *p="Hello";


printf("%s\n",p);


printf("%c\n",*p);


*(p)='A'; /*Replace the first letter with 'A'*/


printf("%s\n",p);


return 0;


}








I am using Linux operating system. In windows probably it will not give a segmentation fault.

Why does the following C code give segmentation fault?
Please see http://c-faq.com/decl/strlitinit.htmll .





You're creating a constant string literal, and then trying to modify it. Effectively, you're trying to write over read-only memory, and this is why a segfault occurs.





You could use Windows if you suffer from the "blame Linux" mentality. You'll get a segfault anyway, though.
Reply:To be able to manipulate bytes using a pointer, try using malloc to allocate a block of memory.


char *p = malloc(6);


strcpy(p, "Hello"); // copy string with trailing \0


*p = 'A';





The code you are using points p to a string in a constant table, and the program cannot write to the address.
Reply:As another person explained, you're replacing the


contents of the literal string "Hello", which the


compiler implementation is allowed (but not required)


to place into a read-only memory segment.





For example, on Solaris using the Sun compiler, this


does not cause a segmentation violation by default.


However, if you compile with the "-xstrconst" option


(which puts literal constants in read-only memory),


then of course, it does. The point is that it will


vary from platform to platform.
Reply:Don't use char *p="Hello";





Use





unsigned char p[] = "Hello";





#include%26lt;stdio.h%26gt;


#include%26lt;string.h%26gt;


int main()


{


unsigned char p[]="Hello";


printf("%s\n",p);


printf("%c\n",p[0]);


p[0]='A'; /*Replace the first letter with 'A'*/


printf("%s\n",p);


return 0;


}





The static allocations by the complier are just that "static". For even more fun, compile your "broken" program with full optimization. You'll get no errors and of course no "Aello". The compiler optimizes out the write to read-only segments.


Need help with a c program?

I'm programming a bot to connect to IRC. I'm fairly new at C, and I need to know efficient ways to keep the program from exiting at the end of the main function. As of now, the bot connects and the programme ends, how do I keep it running so that the bot will stay there and I can move on to my next challenge of responding to PINGs





this is what I have


(very dry because I'm trying to make it work before I try new stuff)





if (connect(sockdesc, (struct sockaddr *)%26amp;their_addr,


sizeof their_addr) == -1) {


perror("connect");


exit(1);


}


char *connectreg="NICK test\r\nUSER testbot test test :My bot\r\n";


len = strlen(connectreg);


send(sockdesc, connectreg, len, 0);


return 0;


}





I need it to keep running so that I can start responding to PINGs after the send call.





My main goal as of now is to make it idle on the server, then I'm going to clean up the code a bit.





PS: I'm compiling under a linux system.

Need help with a c program?
You should put it in a while loop, i'm not familiar with C socket but Java socket. And then put a read from the socket stream there, the read will basically wait until there is an input from the remote side.


This is my pseudo code for this





send start signal to server





while(true)


{


readSignal from Server


process Signal


switch (signal)


case signal1 : handle and send proper signal back to server


case signal2 : handle and send proper signal back to server


..etc


}

sweet pea

Is fwrite in C blocking call?

Is fwrite in C blocking call from the app point of view? For example, if NFS is used as i/o, will the fwrite to a file residing on NFS mounted to the Linux be blocking?

Is fwrite in C blocking call?
yes, fwrite() is a blocking call - your program will not return from it while it is being processed.





Non-blocking calls only exist in programming environments with native threads, such as Windows. They do not really exist in UNIX. On Unix, non-blocking I/O within the same process is achieved using other tricks, such as select ( http://www.scit.wlv.ac.uk/cgi-bin/mansec... ).





Non-blocking equivalent of fwrite() on Windows is WriteFileEx():


http://msdn2.microsoft.com/en-us/library...


Which programming language (other than C++ and Visual Basic) is suitable to develop CD/DVD burning software?

In the future, after graduated, I plan to develop an open source CD/DVD burning software which have all the following features:





1) Burn: Data CD/DVD, Video CD (VCD), DVD video, Audio CD. if possible, include Blu-ray disc.





2) Convert: all video files to VCD/DVD format, Audio files to MP3 format.





3) Backup: Any files, or entire computer.





4) Copy: disc to disc, disc to image (example: ISO), image to disc).





5) Edit: video and audio files





6) Supported operating system: Windows, Linux, Mac





7) Price: always free, including the source code.





I don't want to use C++ and Visual Basic

Which programming language (other than C++ and Visual Basic) is suitable to develop CD/DVD burning software?
Probably you would not write all this functionality but reuse libraries for the majority of it.





Due to this, you are more concentrating on the interface. You could look at c# but its mostly windows only (can work on Linux, but limited)





Java is portable and you can use c libraries, but the interfaces tend to suck a bit in my opinion on java apps.





You could use c/++ but I don't think you need to go to so much trouble when your main task is the interface.
Reply:There are a lot of languages that could do this but I think you are looking for a powerful language that easy and reduces the development cost. I think you should take a close look into C#.NET 2005 Express Edition. It's free and surprisingly powerful. You are working with audio and video, and this means you want your software to function at maximum speed. C# offers a number of unsafe execution techniques that could do the job. Beside that it is a .NET language, and this means easy development and debugging platform.


My computer c drive missing....help?

i installed partition magic to seperate my two drive to install linux andwindows vista ultimate. i had already ulitmate. but after insatlling partion magic it says your disk drive is an error, so i fixed it and after that i tried to uninstall it, when i tried to uninstall from control panel, computer shut down. and then i restarted it says windows cannot be loaded.


i tried to install fresh copy ultimate but it says ur c drive is formatted, and that time i dont have any partition magic software to do it, then i tried to restore dell restore from d drive which is only available. but after few seconds of formatting it crashed as well. so now i cannot access my system.





so guys i m in big trouble. i want to restore all my data which software i should buy/download? or is there any option to get those data ? and if any company does it near north london?





thnak you

My computer c drive missing....help?
As far as i think -FORGET your data.Now what you can do is run fdisk and make new partitions and format them or install xp directly and make new partitions and reformat.
Reply:i think unistall data recovery software may work in this case
Reply:Use your Vista install disk and delete your partition.


Don't go any further or format if you are going to keep Windows Xp.


Put the Xp disk in and let install a fresh copy.


If you want Vista, go ahead and put up a new partition, a large one, 80% of your total disk size at least and let it do it's thing.


"lex.yy.c"?

In my college days I have written programs which has "lex.yy.c" in it.


Now i want that language again to do some programming


what was that?


how can i get that compiler again?


is there a site to download that?


will that compiler run in windows?


do i have to install linux for this?


I googled to get : http://en.wikipedia.org/wiki/Lex_program...


Sounds very familiar.


P.S: I studied this on 6th sem of my engineering.


Computer science engineering Cochin University, Kerala.


Help!

"lex.yy.c"?
Yes, this is Lex and it is Wonderful, but in the beginning a little bit difficult.





Lex is a Lexical Analyzer, you can use it in several way, one that should be most used, is to convert a sequence of characters in your C source code into a sequence of tokens.





In this way you can, for example, crate your custom Makefile that compile on different platform and different operating systems.





To use it you need to read and read and read and try it.





This http://gnuwin32.sourceforge.net/packages... you can use on Windows, but I advice you to follow the links inside the wiki that you posted to understand clearly what are Lexical Analizer and how to use them

rose

Anyone know of a good c++ compiler?

hey i was thinking of getting back into c++ and i was wondering what a good compiler would be? and i know about linux compilers but i kinda dont have enough space for 2 operating systems again i only have 20 gigs and i want to keep it simple use it on windows anyone know of a good one thanks in advance =)

Anyone know of a good c++ compiler?
windows have a good one. This is the link http://msdn2.microsoft.com/en-us/visualc...


How to use IPC here (C++)?

Lets say X is a shell command that will get you into X-shell upon execution. There's a command, a module, Y that can be run only in X-shell. How can I run Y from a C++ code? I need to somehow tell my app that the environment it'll be dealing with will be X-shell and not the Linux shell. I haven't dealt with a case like that before and don't know how to incorporate IPC here. Would I take X-shell as the parent process and the spawned child as module Y? Not sure... I should point out that it's not possible to do something like "X-shell -c Y"; first X-shell has to be executed. Once in the X-shell environment, now Y can be called.





A word of wisdom is appreciated.

How to use IPC here (C++)?
Good question. If I remember correctly, can't you use one of the flavors of execve(...) to execute a script that puts you in the X-shell before running the Y command that needs to be run in this X-shell?





...


(in your C++ code)





execve("/bin/example/myscript",...)





...





/bin/example/myscript looks like:





#/bin/X /* putting you in the X-shell */





Y-command /* running the actuall Y command here */








Any way, this is off the top of my head but maybe it'll help a little bit.


Just how possible is it to make a command line hex editor for Linux?

I am very curious as to experimenting with these programs, and I have downloaded a graphical one named KHexEdit. I am using a Linux computer and am wondering as to how one could be made to work in the terminal. For example, I am just looking for the basic program without any GUI so I can learn how to make one. If anyone has any help on how to make one, please explain. I would also appreciate it if you could explain how to program one in C, if you can tell me. Otherwise, any way to make one is fine.

Just how possible is it to make a command line hex editor for Linux?
If you are a skilled enough programmer, probably not too hard. If you don't know file structures, you don't know programming, and you don't know how to use google to find such information - lotsa luck! You will need it!
Reply:Why would you want to make something that already exist?


C++ question; how do you get your program to read inputs from a txt file?

I know that it can be done in the Linux terminal, and using the Cygwin environment for WinXP. All the text file contains are numbers (type double) separated by spaces.





Problem is that Cygwin doesnt work too well on my system.


How do I make it happen on BloodShed Dev-C++ ?





I am a first year Engg. student with no prior programming experience, so I would appreciate if you answered in plain dumbass. Thanks in advance.

C++ question; how do you get your program to read inputs from a txt file?
I have no idea what role Linux or Cygwin plays in your question. You can open and read from a text file in a portable way (i.e. it doesn't matter if you are on Windows, Mac, Linux, BSD, etc.).





I'm not sure where to start explaining. So instead, I'll point you to tutorials, as I have a sinking feeling you haven't done much reading.





http://www.cprogramming.com/tutorial.htm...





Just go through the C++ tutorials please. If you don't understand a specific portion, ask a specific question. Rather than "how do I do file input".





(The answer is open up the file with an fstream. Then acquire each line in one of several ways. Either cin each token on the line, or use getline and break down the line by spaces).
Reply:You can use the ifstream class found in fstream.h.





ifstream input("file.txt");





you can now use input just like you use cin, except you'll be reading a file instead of keyboard input.

flowering plum

Speed comparison of modperl vs. C++?

We are starting a development project and we want to be able to support as many simultaneous users as possible.





We are doing a lot of things in Perl and want to speed up key portions via using C++.





However, one of the programmers thinks that using ModPerl will result in something that is as fast as C++ and takes up as little memory (RAM) allocation.





Is there any good data on the comparison of speed and memory usage between ModPerl and C++?





If it helps we are using Mysql as our databsae back end and the environment is Red Hat Linux.

Speed comparison of modperl vs. C++?
good question!





Certainly Perl is faster to code. and good perl is shorter and more concise. Perl relies on C code on the inside, and compiles (similar to java) so it's not classically interpreted.





as far as size, they will be similar, because of modperl's reuse of resources. Most often the size in memory is more linked to the data, not the program.





Since most of the hairy code is actually in the database internals, there is no difference there.





Perl give you fast flexible code. but the bottom line is what the programmers know. Don't try to get great perl code from a C++ only programmer. Or vice-versa.





bottom line


speed to develop... PERL


speed to run... similar








additionally Perl %26amp; C can co-exist (even in the same source file) so everyone can contribute to the project!
Reply:I would say C++ is better at application programs Modperl would be faster then C++ cause it uses Apache API calls and is interpreted other then compiled.


With 80 gb sata hdd i have six partitions c:/[18.5gb],d [18.5gb], e[18.5gb], f[10 gb] ,g[8 mb],h[8mb ext3]?

here partitions c:/ and d:/ are both Fat32 type of file systems, partitions e:/ and f:/ and g:/ are all three are NTFS type of file systems while the partition h:/ is with the file system of ext3 type .


i have already three operating systems installed in my system which is c:/ windows xp professional , d:/ windows xp home , e:/ windows xp professional x64 bit edition. and f:/ is just empty with available space of 10 gb.





now please tell me how to creat the partitions for two new operating system which i wana install in my system [ the red hat linux and the ubuntu both linux operating system ].


thanking you ....!

With 80 gb sata hdd i have six partitions c:/[18.5gb],d [18.5gb], e[18.5gb], f[10 gb] ,g[8 mb],h[8mb ext3]?
its easy


boot system with linux os cd


1. reach till manual partion option come on screen.





2. delete the ext3 partition. not create a new /boot, /swap and / all ext3 type (remember swap is type itself).





3. space must be 100, approx double ur ram for swap and balance of it for linux red hat native.





4. in case you wish to load upuntu also then hold back some space in /native





5. Now delete that space and liberate it as free space.





6. install linux redhat





7. after installation now boot with ubuntu. and follow same procedure, but remember this time the space left after step 5 is to be used. steps 3-4 to be repeated for same.





anyprobs pm me


take care


all the best
Reply:4 os in 80 gb.. god thats amazing truly amazing
Reply:Use two of the empty partitions. Leave the H partition alone. Your two Linux distros can use it as is. Also, Windows cannot read a Linux partition but Linux can see and use a Windows partition. You might be better off using a virtual machine for your various OSes. A VM work inside of a host OS. It acts just like a PC and you can do anything with it that you can with your host system including networking the VMs. Check out VM Ware. They have a free version that you can download. In your case, use the XP Home version for the host. Have fun.
Reply:why? ... I mean really ... why?





What do you need with that many operating systems? All of your HDD is being used up by OS, do you have any other programs running off it?





What is your purpose for this machine?
Reply:you need to create 1 ext3 and 1 linux swap partition for each linux. the ext3 partition must be enough to accommodate the OS files. creates swap space equal to the amount of RAM.





create all partitions as logical partitions.


Anyone can solve my C Query ??

In C Programming, with TC++ 3.0 and Windows 98 SE, the output of the following code would be 657. Why So ?? Also note that output would change with LINUX.





main()


{


printf("%d",main) ;


}





We have this as an explain the reason question in our Post Graduation C examination and I am unable to find satisfactory answer in the search engines.

Anyone can solve my C Query ??
U may get surprised to know that it's a garbage value, but this value is not guaranteed, u're using Turbo C++ IDE compiler, so u're getting 657, use Linux u'll get some other value.





So, again I'm saying '657' is garbage. More specifically, the program invokes undefined behavior, and anything at all might happen. On the system you are using at the moment, "anything at all" appears to be "print 657," but that is not guaranteed.





The program exhibits undefined behavior for two reasons,


and "peculiar behavior" for two more:





- It calls a variadic function without a prototype in


scope. Functions that take a variable number of


arguments -- like printf() -- must be properly


declared before use, or undefined behavior results.


The best way to declare printf() is to #include


%26lt;stdio.h%26gt;.





- It uses the "%d" conversion specifier with a value


that is not an `int'. `main' in the printf() call


is a pointer to the function named `main', and a


function pointer is not an `int'. When you tell


printf() to expect an argument of one type (`int')


and actually supply something different (function


pointer), undefined behavior results.





- It fails to end its final (only) line of output with


a newline character '\n'. On some implementations,


the output may not appear at all unless each line


ends with a newline.





- It "drops off the end" of the `int'-valued function


main() without returning an `int' value. If the


environment tries to use the value returned by main()


as an indication of the program's success or failure


(most environments do this), great confusion can


result if main() fails to return a value.
Reply:This is odd, and not what I would expect in the environments I have worked in. You are interpreting the address of a function as an integer, and it is coming out very small.





I suspect it has to do with integer size. The size of an integer is not defined by C, and can be 16 bits. I bet that on this architecture addresses are 32 bits and integers are 16 bits, so this is picking up the top 16 bits of the address field.





So what is this address? Looking at the bit pattern (binary)


1010010001, this probably is a page boundary where the executable is stored, and the first function listed is main.
Reply:%d is the...symbol for integers, so what you see int he output is probably the numerical value of the word main(I think)





Try replacing %d with %s, and main with "main".


As far as I remember, thats what you need for string output in C.








It might be different in Linux because Linux might be (might be(might be)) using a different character code.
Reply:Here are two possibilities for to grapple with: (unless you just want to convey that advanced degree on ME).





When you use %d, you are asking it to print an integer. For one system, and integer might be an 8 bit byte, in another system, it might be a 16 bit byte... and in a third system, it might be a 32 bit byte. For Windows 98SE, it's just 16 bits.





When you ask to print an integer of the starting address of the routine main (which is a bizare thing to do), you could get just about any darn thing to print. Of course, when you recompile under linux, it will display some different sort of bizzare answer. TRY IT with both systems.





Good luck


C program should open up another application while executing...?

need a C lang code which should open up another application (say an .exe file) while executing...


platform: Windows





i knw it can be done using exec() call in linux, but how to do it in windows?

C program should open up another application while executing...?
#include %26lt;stdlib.h%26gt;


#include%26lt;stdio.h%26gt;





int main()


{


(void)system("C:\\Windows\\System32\\n...


return(0);


}





I took this code from :


http://www.daniweb.com/forums/thread1068...





Please alos check this:


http://www.programmersheaven.com/mb/Cand...





I am sorry, I don't have C / C++ IDE on my system right now so could not check these. I hope they work. Thanks

nil

Can i copy a windows drive to another hard drive in linux?

my C drive is making obnoxious noises and my computer has been running like crap lately, so i'm suspecting the drive is near death. i have on it 2 boot partitions, one xp and the other ubuntu.





is it possible to create a partition on another drive, and copy the windows partition over to it so i can boot from there? would i be able to do it with linux so none of the windows files would be in use?

Can i copy a windows drive to another hard drive in linux?
If you want a bootable Windows installation, the partition to which you copy your current Windows install has to a be primary partition, and whatever you're using as a boot loader has to know about it, and be able to transfer control to that partition (hook BIOS int13 for that partition). dd copy can do the partition copy. Here's a dual boot primer for Debian Sarge and grub:
Reply:Not a possibility.! you need to understand that file systems for a windows machine and that of a Linux machine are very different.. so inherently files you copy in lunix are rendered useless in a WIN FS and vice versa. What i would suggest is that you get an external HDD and move your windows partition there. Then for the previous partition the same and perform the same for linux if you really want to continue with this hard drive. Take my advise, dump this drive and buy a new one.


HOW 2 INSTALL WIN XP PRO (SP3) when there is linux OS installed on primary drive without loosing DATA?

I HAVE INSTALLED BLAG LINUX ON MY PRIMARY DRIVE.THE DRIVE IS FROMATTED IN ex2t OR ext3 FORMAT.WHILE I HAVE NTFS DATA ON OTHER DRIVES.HENCE I CANNOT ACCESS NTFS FILES %26amp; SOFTWARES THAT I HAD INSTALLED WHILE I WAS USING WIN XP (SP2).





I DONT WANT TO LOOSE MY DATA! WHAT TO DO.WHEN I BOOT WITH WIN XP CD IT SHOWS:





F:[UNKNOWN PARTION]


D:[5.5 GB]


C:[75.GB-FREE 43 GB]


Running yahoo messenger on wine in linux?

Iam interested in running Yahoo Messenger 7.0 Windows version in my OpenSUSE Linux using wine. The installation (with $%26gt;wine msgr7in.exe) proceeds till it has to write some registry settings where wine shows errors like WIN32_FIND_DATA data not written. The installation "succeeds" but there is no ysmgr*.exe file in the "c:\program files\Yahoo\Install\Messenger" folder, or any other folder in the ".wine" folder.


I know that there are other chat programs that support Yahoo Protocol, but any help in this will be appreciated.

Running yahoo messenger on wine in linux?
I had a similar problem on Linux but then had to use GAIM which comes bundled with OPENSUSE 10.


Does not have all the features that Yahoo Messenger 7 has but at least it works.





Cheers!
Reply:In case, you just want to communicate using Yahoo messenger, go to www.e-messenger.com and login using your Yahoo ID. A pop up window would come up with the same Yahoo friends and interface.


I'm going to be getting a new computer.Would you recommend putting linux on my old machine to learn to program

I'm getting my bro's computer and I want to do something with my old one. I'm interested in programming and I was wondering if it would be recommended to teach myself LINUX.





I already know 3 different BASIC languages, html, javascript, and teaching myself C++, so I have some experience already in programming.

I'm going to be getting a new computer.Would you recommend putting linux on my old machine to learn to program
Yes.





If you are just beginning check out Ubuntu the very latest release is QUITE Impressive.. in the desktop and the server side of things..





youd be suprised everything you can do.. and itd be a very great experience for you








Ubuntu 7.04 - Feisty Fawn


http://www.ubuntu.com/











Hope it helps!








Blue Chip Hosting staff,


http://www.bluechiphosting.com
Reply:yeah, definitely...Linux is great...no point letting the old computer go to waste
Reply:There's not much can be achieved financially by programming for Linux as it is free. To earn money at it aim for the Windows market and the Mac market, that's where money can be made.
Reply:dude just go. you already know the answer. its a new challenge.


My flavor is ubuntu. and theres xubuntu for older pc's


come on take the leap: http://www.ubuntu.com/


heres the best help forum on earth: http://ubuntuforums.org/


earthday 4/20 :P
Reply:If you're interested in learning, I would suggest that you go ahead with installing Linux on your older computer and looking at an operating system in a different view than what you are used to. Also, you can learn shell scripting which will be very useful to automate a whole load of tasks. You can move forward with C++ also, as Linux comes with a built in C compiler.

sp

How do I install Ubuntu Linux?

My hard drive has 3 partitions


one with Windows Drive C:


the second Drive D: which has recovery data


and the third Drive E: which is totally empty and is the drive that I want to install Linux on how do I do that?

How do I install Ubuntu Linux?
Thats what I wanted to know , good question !





Many thanks to the person with the 1st answer , although the download link isnt working , so I'm going to search for wubi on the net.





I hope it helps my install coz I have windows on C: , Downloads on D:(seperate drive) , Games on E:(partition after C on disk 1) , Media on F(seperate drive) , and a further seperate drive in a USB caddy (H) , G is the DVDRW , so with this in mind I may need a bit of luck LOL.





Many thanks again for the question AND especially the answer , gave it a thumbs up :)
Reply:I did a search on wubi not too long ago. It too has its problems. I find setting up a dual-boot fairly straight forward, and no doubt the harddrive installation is more stable and faster.
Reply:Try Wubi, it's safe(r) then traditional installations, and is a lot easier to work with. http://wubi-installer.org/


It only works with the Ubuntu Distros, for 7.04. After installing and running it from the E: drive, do a quick search for updates, and you'll get Ubuntu 7.10. Hope this helps.


I want to install suse linux with Dual boot with windows, help would be highly appricaited?

Right now i am using windows xp, installed on my c drive,total hdd size is 40 gb, other partitions available are D,E and F. Now i want to install suse linux on some other partition say D so that it wont disturb any windows settings how can i do that.


Thanks a lot in advance

I want to install suse linux with Dual boot with windows, help would be highly appricaited?
just pop in the cd and tell it to install to the partition u want, since the operating systems are on different partitions they wont have any trobles with each other.


Which one is better High end PC with Linux / Workstation with Linux?

I am considering to buy a high end INTEL PC with Dual core 2.6 GHz, 2GB RAM, 120 / 160 GB HDD with Linux O/s - which might cost about Rs. 50K.


Is it worth going for a WORKSTATION with P4 3GHz, 512 MB RAM, 80 GB HDD which will cost me almost Rs. 65K


Applications are mostly programming in C / FORTRAN, AutoCAD, Data Base, etc.. not for gaming.

Which one is better High end PC with Linux / Workstation with Linux?
Dear friend, looking at the kind of applications you prefer to use on the sytem, i would suggest you to go with High end PC with the specs you have mentioned. thats very much enough for your applications.





Workstations are required if you are running some programs involving huge DB servers %26amp; high grapic games.
Reply:i must prefer to buy the pc with linux or pc with windows OS.. i like them both
Reply:PC with Linux , Windows os


Can anybody help me with installing Red Hat Linux 7?

My Hard Drive has two partitions. The 'c' Drive (116 GB) contains Windows Vista Home Basic and the newly created 'e' Drive (111 GB) is a totally empty NTFS partition. I have the Red Hat Linux CD's but need help with the options showing up on the screen as they relate to creating partitions but my partition on which Red Hat Linux is to be installed is already in place. I am finding the Red Hat installation process much more complicated than a Windows installation. I could really do with some help here. (Anybody out there in the NW10 area of London, England? That's where I am)

Can anybody help me with installing Red Hat Linux 7?
go to tyork@yorkinfo.com he is the best at this stuff
Reply:Linux will not run on an NTFS partition. I have 2 recommendations.





1. Use suse linux (it will be an easier install) http://www.opensuse.org or the latest redhat disro now the fedora project ( http://fedora.redhat.com )





2. If you can install linux on a different machine do it. Linux does not need the power that windows does. A 300 MHz processor will suffice with 256 meg of ram.





RJ

radiata

How to learn programming languages Linux and programming?

i want to learn linux and basics of programming and i just dont know how what to i do where do i learn python and c and java etc etc and how to practice and wtf is that all????





i know my question sounds like i am an idiot,but i really know very little about that stuff.thanks:)

How to learn programming languages Linux and programming?
Everyone starts out a beginner. Only the hard working and diligent remain. Have you bothered googling? Countless beginners have started. Many of them got by with Google.





Want to learn Python? Go to the Python website. %26lt;%26lt; READ %26gt;%26gt; the website documentation. They mention beginner tutorials, books and so on.





Want to learn C? Get a book like K%26amp;R's The C Programming Language.





Want to learn Java? Try their website. They link in tutorials and books.





How to practice? Write programs. And more programs. And more programs.





Confused? Google. You're not the 5th person to try learning programming. You're one of countless millions. Chances are, your question has been asked and answered already. And you can find the answers with Google.


I have a imac g4 the harddrive has been erased i want to install something on it Linux or Mac os x I have the?

Mac os x Panther but its a dvd and the bottom of the imac says its a cdrw if I cant install that How would I install linux on it.. I tried putting in Unbuntu and holding down the c button but nothing happens

I have a imac g4 the harddrive has been erased i want to install something on it Linux or Mac os x I have the?
Sounds like stolen goods! why don't you have the original disk? why don't you go to an apple store, and get a cd version... free for cd only machines.





unbuntu is normally intel, yellow dog linux is power pc. What do you have?
Reply:Dont use ubuntu teh free linux that thing is so cheap I tried it.


What C/C++ Compiler should I use?

C/C++ have many compiler, for example, Dev C++, wxDevCpp,Borland C++ Builder, GCC etc. So who can tell me Which C++ compiler should I use?


By the way I try to search about GCC by Google,and I download it, but I don't know how to install,if you suggest me to use GCC please tell me how to install and use it , I want to know about GCC,because Linux Sourse is design by GCC, so I want to know about it(GCC), Thanks a lot!

What C/C++ Compiler should I use?
The one i use and find myself very comfortable with is Dev C++.


Here is the site from which you can download it:





http://www.bloodshed.net/dev/





For further help in programming you can email me at maqsood_rahman@hotmail.com





Wish you all the best!
Reply:gcc - supports the most architechtures, has the most libraries, very advanced, most popular in open source community.





visual c compiler - fast code, not as flexible as gcc.


most popular in closed source community.





digital mars - very fast code very little support.





bcc - deprected, was good.





gcc is #1.





only use Microsofts vc++ compiler if you have reason to do so.





also note that things like devc++ and codeblocks use GCC as there compilers and are correctly described as IDE's.
Reply:I really like Dev-C++.
Reply:ok i know im late (sigh) DEV-C++


How to format ntfs or fat32 file system for linux installing?

already, i have winxp os.


how to install linux on my one ntfs or fat32 file system.


My hard disk drives are c:,d:,e:,f:,g:,h:.

How to format ntfs or fat32 file system for linux installing?
Ideally you should have an entire hard disk only for Linux; this way if you crash Linux your Xp will be left untouched. Just make sure , at install, to select "use entire disk" and pick it - all the formatting will be done automatically, next choose it as the location for the bootloader. Don't forget to pick it first in BIOS boot order.


You could select "use existing partition" and selecting one( also auto format) but this way the bootloader will overwrite the Xp one and if you trash your linux you may end up in (not big, but for a begginer nasty) trouble.


http://www.mandriva.com/ or http://www.pclinuxos.com/ are ideally suited for begginers (no drivers or complicated configurations required), and you don't even need to install them to try them, just boot from the optical disk and run them in Live-CD mode.
Reply:Do a bit of reading, preferably via google, or the website of your preferred distros, don't rely on the postings you are going to get here!





I have installed Linux many times, on a variety of different computers, and only two machines have had a separate hard drive for Linux, NONE of the installs have had problems, and I don't see any difference in performance.





You have to understand formatting of partitions, and you have to understand how Linux names partitions. Once you understand that, it is easy to reformat the partitions that you want to use for Linux, and assuming there are no hardware issues, your installation should go quite easily. If you don't understand these basics, IMHO you shouldn't be messing around - get someone who knows what they are doing to help you.

medium

Can I use a Linux Server as an Open Directory for XP?

Let me put things simpler. I'm building a Linux server for a client, and the client wants to have 5 terminals running Windows XP.





The way he wants his system to work is that when the XP user logs in. His complete user profile including desktop documents and any other files that are saved in his 'my documents area, are obtained from the server, yet saved locally for offline use.





This is why he wants this system:





If his computer disappears tomorrow, he can login from a new computer, and everything including the stupid little picture of his dog on his desktop will still be there on the new computer.





This goes without saying, that if he saves something on c: separately, or on another partition it will be lost with the old computer.





This is apparently native in Microsoft Server 2003, I just want to do this for free using open source software. Someone told me that you can use Samba to do this. From what I can tell, Samba only handles basic LDAP. Not complete Profiles with files.

Can I use a Linux Server as an Open Directory for XP?
You can use Samba like an NT 4 Style PDC for authentication and setup Roaming Profiles just like a MS Domain.


Finding home folder in linux?

I'm trying to download starcraft on my linux and the instructions tell me to run a command involving the home folder.





the command is:


[path to home foler]/.wine/drive_c/Program\ Files/Starcraft/





Where is the home folder? And what do I type in there?

Finding home folder in linux?
/home/username





I'll show you how I get Filezilla to work in Linux, as an example.





I download the setup.exe file for Filezilla. When I double-click on it, Wine will try to open the file. Then, the installer appears, just as if I were using Windows. Instead of installing Filezilla to [C:\Program Files\Filezilla\]


,I'm going to override the default installation location and install it to [z:\home\username\.wine\drive_c\Program Files\Filezilla].


For some reason, [z:\] is what Wine calls my Ubuntu partition.





Then, I set up a launcher (on the panel or in the menu) for the command [wine "z:\home\username\.wine\drive_c\Program Files\Filezilla\Filezilla.exe"]


That's it. Now when I click on that launcher, Filezilla will load up.





Edit: Here is a Wine Quickstart Guide


http://frankscorner.org/index.php?p=quic...





Edit2: [path to home foler] = path to downloaded file.


Sleep(1) replacment in visual c++....?

our professor gave us a sample of recursion in c++ (in maze). since, this code is meant to be for PUTTY or Linux Redhat Terminal.....but when i try to run the code in Visual C++ compiler...it gives an error saying that sleep(1) is an undeclared identifier....i believe by having sleep(1) in the code means that Java predefined function is being called but i am not sure...is there any way that this code could run in Visual c++ too?

Sleep(1) replacment in visual c++....?
The sleep function is typically used to suspend the current thread for a given amount of time. There are two main reasons for doing this: 1) you're running a multithreading program and you want a thread to go idle for a while so that the other thread gets some CPU time to do its work, and 2) to introduce a fixed delay so that your program doesn't run too fast.





I'm guessing that your professor hasn't given you a multi-threaded program, so that line is probably in there for the second reason. If so then removing it altogether from the program will probably make it run fine, or you can add a dummy loop to burn off a few cycles. In both cases the program speed will depend on the speed of the machine you run it on.





If you really do want to add a proper sleep then it's going to depend on your target architecture, as sleep isn't standard C++ and it has a higher resolution that that provided by the standard C++ time functions. The easiest way to implement sleep is to include %26lt;windows.h%26gt; and used Sleep(1) instead. For this to work, you might need to change your Visual C++ project settings to use the multi-threaded runtime libraries instead of the single-threaded ones.





Doing it properly, i.e. for a commercial app, is usually a bit more involved. Typically you set up a loop during initialization to burn off some cycles and then count how long it took, this value is then used as the counter in the sleep function to generate a reasonably accurate sleep time. Doing it really accurately requires low-level assembly, but I'm sure that level of accuracy isn't needed in your case.
Reply:Try it like this:





Sleep(1);





...uppercase 1st letter.





Also, it's Win API(apparently)...not avail in console apps. MSVC would NOT compile with it (Sleep()) in the code of a win 32 console app, but a Win 32 GUI app did compile and run.





Here's from MSVC help:





The Sleep function suspends the execution of the current thread for a specified interval.





VOID Sleep(


DWORD dwMilliseconds // sleep time in milliseconds


);





Parameters -- dwMilliseconds


Specifies the time, in milliseconds, for which to suspend execution.





---- if that won't work for any reason, try this:





#include %26lt;time.h%26gt;


/*--------------------------------


sleep()





Works like old Borland TurboC Delay() but only if clock


granularity is millisecs (thousandths of sec)


look for CLOCKS_PER_SEC in time.h file





This function should work in millisecs in MSVC++


IE: a call like so:


sleep(1000); // yields a 1 second delay


*-------------------------------*/


void sleep(long d)


{


clock_t start=clock();





while(clock() - start %26lt; d);


}


How do I boot my PC with Linux without installing it? it already has windows on it.?

Hi, I was wondering how do I boot my PC with Linux without actually installing it because it's not just my computwer it's the family computer and as such I really want to try Linux out but I need to know how to boot it up and run it without installing it. I know on a Mac Book all you do is put the disc in, turn off the Mac, hold down C key, and turn the mac back on so is it the same way with PC's?

How do I boot my PC with Linux without installing it? it already has windows on it.?
You need a LiveCD. (Try Ubuntu's)





Boot Windows, Insert CD and Reboot.


It should load Linux from the CD automatically, if it doesn't check your BIOS is set to boot off CD before Hard Disk.
Reply:just put the cd into the drive and start the computer , it should start from the cd. if it does not then you have to make some changes in the bios but that is a tad more complex.
Reply:What you are talking about is called a Linux "Live CD". Two good Linux distributions with live CDs are Ubuntu and Fedora, but if you have never used Linux before, I recommend Ubuntu; it is aimed for people who know less about computers/less advanced users.





To burn a Ubuntu "live CD" go to http://www.ubuntu.com/getubuntu/download and choose the option that says "Ubuntu 7.10 - Supported to 2009". Make sure you have a burnable cd with 700 mb of space free! Burn the .iso file onto a cd (Don't worry about any special options, just burn it.) Put it in your cd drive and when you start your PC, press F12 for boot options (It can vary). Tell it to boot from the cd rom and then I think there's an option to use the live cd. Actually, according to some official Ubuntu documentation, this is how you do it:





"After you burn the cd (See BurningIsoHowto for help if needed), pop it into any computer and reboot the computer. Ubuntu will load. After you are done, shut the computer down and remove the cd."


so maybe it's simpler than that. It's been a while for me.





Hope you find this useful.





Note that I didn't see the additional details until after I posted this.
Reply:Ubuntu Linux is a fake distro. It is legal to still open source software and rename it since it's open source. But doesn't not mean that it's a good thing. Ubuntu is packages taken from Debian Linux and renamed with the Ubuntu name at the end. Of course most Ubuntu people are newbies and will deny this but all patches, bug reports and so on from Ubuntu are lifted directly from Debian. Even the change logs are Debian. You should keep this in mind. If you use a clone or hack you will get second hand support. If you want to use a Debian based distro I would suggest that you use Debian and give them the credit they deserve.





Mint Linux is a bit better then Ubuntu as they are not trying to take Debian packages and rename them to take the credit. Mint actually says it's based on Debian. However again if you want Debian just get Debian.





I myself Have created my own Original Linux Distro called Myah OS. You can try it out at http://myah.org But I will try and give you some unbiased help here not just push my own. So here is a list of Real distros that I would suggest for a Linux newbie that look good and work well to.





You can use any LiveCD you just need to tell you PC to boot off the CD usually something like pressing F10 or F12 during bootup. Also newer computers can also boot off of USB if you have this option then you can do LiveUSB and is much better then the CD one since it leaves your CD drive open so you can use it later. And it also runs much faster since you don't have that CD lag where you klick and wait for the CD to spin up. A USB 2.0 is usually much much faster almost harddrive speeds but still live.
Reply:get pclinux livecd... boots off the cd and you dont need to install it if you dont want to.

cvs

What is the scope of oracle with linux?

i m student of bca waiting for my final year result.i am working in leading traing institute as faculty for oracle sql,pl/sql and c ,c++ also.i want to opt database as my career.yesterday i went to HCL traing center for guidence,he told me that there is good scope for oracle on linux plateform. but i have heared that Java is must for oracle profrssionals, is it true please.

What is the scope of oracle with linux?
Please Dont Mixup two distinct things. As far as Java is concerned, of course this is not mandatory BUT give you more and more additionals in order to grow.


But, Combination of Oracle with Linux is no doubt, will be more beneficial for you. Keep it up.


Windows restarts while loading and C Drive is completely unaccessible !?

My PC probably got affected from a Virus that might have had come from a Flash Drive causing Windows Xp to reboot when the "loading windows xp" appears on the Screen.


Furthurmore the C Drive is completely unaccessible as I try to access it from Linux-Fedora which says "Unable to mount Drive" (The Drive WAS accessible from linux before the virus did the damage)..


When I try to re-install windows, there is just a blank screen after I select the option to "boot from CD"...





What steps should I take inorder to solve this problem ?

Windows restarts while loading and C Drive is completely unaccessible !?
give install frsh copy of xp and follow on screen procedures


What is the equivalent of a .exe file in Linux?

Most of the time If you download something for Linux its a .tar.gz or .tgz but thats more like .rar or .zip file and then inside it is a bunch of C source code, so do I need to compile it? if so to what? I heard that .exe files won't run on a Linux machine so if I'm supposed to compile it what do I compile it to?? Any help would be appreciated (I'm good with Windows but a blundering idiot with Linux so keep that in mind if that helps)

What is the equivalent of a .exe file in Linux?
Learn the command line. The equivalent of an exe file in Linux is an ELF file. It is also used in Unix. Generally, it has no extension at the end. A look in your /bin /sbin /usr/bin or /usr/sbin directories will show you that programs like cat, tar and gzip don't have file extensions.





A program will execute if it has permission to execute. type "man chmod" in a terminal for more information on the subject. If you have just switched to Linux, then it is a very good idea to learn what the default method of installation is: Yum for Fedora/Red Hat, emerge for gentoo or apt-get for Debian and its derivatives such as Ubuntu and Knoppix (I generally use wajig which is a front end for apt-get on my Debian system). You can install from tar-gz files, but that is not recommended because if you run into bad trouble (which you can) and have to reinstall, you will lose any package you didn't install using the default, and many which you did. That said, sometimes it is necessary. If a package has C code, you probably do have to recompile it. If you are on Ubuntu, there is one necessary step first: install the package "build-essential" either from whatever front end you use or by going to the command line and typing "sudo apt-get build-essential" (do a "sudo apt-get update" first). By default Ubuntu does not install all the development packages which by default all the other Linux distros do. Then at the command line, cd to the directory where you unzipped the package and look either for files called README or INSTALL or a doc directory which may have those files in them. Generally they will give you instructions for compiling and installing your program using make from the build-essential package and an executable script in this directory called configure (which you invoke by typing "./configure" with the ./ meaning look in this directory for the command). These instructions do not require a lot of programming smarts, as a rule, but occasionally they do.





You can run exe files on your machine if you have Wine installed. You can check by typing "man wine". If you don't do an "apt-get install wine" (or for Fedora "yum install wine"). Then go on the net and look for documentation for it. In 1990 I had my first experience with the graphic user interface. My immediate reaction was, "This is evil". Seventeen years later my opinion hasn't changed. Learn the command line.
Reply:Good question. You need to extract that tar file. Then you should open the readme or install file using any editor and read them.


Some commands will be given for compiling the source codes.


You should type them in konsole under the same directory.


like


./configure


make


install


It will create the executable file. It may or may not have extensions unlike windows which has .exe extension. .bin is more common in linux for executable file.





Mostly success will be the result. Keep trying.
Reply:If you're a newbie at Linux, don't bother with the tar.gz's, etc - use your built-in installer to find, download, install and check the new programs you want.





In Ubuntu (which is what I use) it's under "Programs" then "Add / Remove..."





You didn't say what distro (flavour) you're using, but if you're using Ubuntu or another Debian-based Linux, and you can't find the program in the add/remove programs... do a Google search for "whatevertheprogramis .deb"





This will find an already compiled version that will probably work just fine!





If THAT doesn't work, search ubuntuforums.org; ask in there if you can't find the answer. They're very, very helpful in there.
Reply:Linux uses file permissions to determine whether a file is executable.





You can see the file permissions for a file by typing ls -l at the command prompt in Terminal.


To find out more about file permissions make a search for "file permissions Linux".





As for the downloaded files .tar etc - they are "packages" of an application (for instance) the vendor or author of the package should provide you with the information what to do with it.





Linux normally knows what to do with compressed files (such as tar files). However, some of this is Linux version dependant.


Anyone created their own Linux distro?

I want a specialized super-small distro (ie. %26lt;50 Mb) like D*mn Small Linux. Which kernel should I use, device driver packages, small app packages etc? I have some programming experience (C, Java, Python) and know some operating system theory but I'm no expert. Is this a project someone with intermediate skills can do?

Anyone created their own Linux distro?
You should try www.linuxfromscratch.org





I tryid the linux from scratch, and I found there was a lot of documentation that helped inform you of what you needed for certain functions from your machine.





Good luck, as it will take lots of time, and plenty of concentration, never mind the de-bugging.





When you have a distro out, let me know, I will help you test it, unless you are making it for a specific machine, which will bring down file sizes because of less drivers.
Reply:I think Linux shouldn't be that hard to modify. Maybe you could start by attending a site like Ubuntu.com or Linux.org and looking for topics that talk about modifying it's contents. However, creating you own distro by yourself might be a hard task, and you should look for a buddy to help ya out. Maybe someone for your neighborhood?





Good luck!


-Jorge Rivera

gardenia

Help: question about linux?

can anybody help me with LINUX.... i need to know very basic things about this operating system and how to program in it (i have knowledge of programming in C++)... any help at all that you can offer? or provide me a link of a site that can help a beginner like me.

Help: question about linux?
I recommend the site linuxquestions.org





There is a forum supported by a very large and active userbase there which is specifically geared to help people with linux related problems, be they complete beginners or guru´s running into a problem stumping them.





As long as you ask concise and polite questions there, there´s someone bound to help you - if the answers to your questions aren´t already listed.
Reply:Linux is a free version of OS provided by GNU community.


Its very easy to use it. But little tough at the beginning but once you master it. Thats it...


You can search for the same in google.
Reply:linux.com


How should i mount my fat32 drives in redhat linux 9.0???

i can c the drives after entering "fdisk -l"- this is the data i get.. how should i move from there on???plz if u could answer in detail??


Disk /dev/hdb: 40.0 GB, 40059321856 bytes


255 heads, 63 sectors/track, 4870 cylinders


Units = cylinders of 16065 * 512 = 8225280 bytes





Device Boot Start End Blocks Id System


/dev/hdb1 * 1 892 7164958+ b Win95 FAT32


/dev/hdb2 893 4869 31945252+ f Win95 Ext'd (LBA)


/dev/hdb5 893 1784 7164958+ b Win95 FAT32


/dev/hdb6 2550 3441 7164958+ b Win95 FAT32


/dev/hdb7 3442 4869 11470378+ b Win95 FAT32


/dev/hdb8 1785 1797 104391 83 Linux


/dev/hdb9 1798 2484 5518296 83 Linux


/dev/hdb10 2485 2549 522081 82 Linux swap








Partition table entries are not in disk order

How should i mount my fat32 drives in redhat linux 9.0???
For mounting your drive D identify the disk name and the number from the fdisk –l listing and mount it as:


%26lt;System Prompt%26gt; mount /dev/hdb5 /mnt/win_d





Similarly to mount the Drive C as per your FDISK LIST:


%26lt;System Prompt%26gt; mount /dev/hdb1 /mnt/win_c





NOTE:


Create a folder called win_d prior mounting the /dev/hda5 partition as:





%26lt;System Prompt%26gt; mkdir /mnt/win_d





And For Drive C:


%26lt;System Prompt%26gt; mkdir /mnt/win_c


Problem with a Linux program under Cygwin?

Hi everybody





I have a program which was written under Linux and it's working fine. I wanted to execute that program in windows using Cygwin emulator . However I've compiled it with gcc with no problems , When I tried to execute this program , Cygwin flagged an error like this : _cygtls::handle_exceptions : Error while dumping state ( Probably corrupted stack ) Segmentation fault


You can access the source code here : http://www.freefileupload.net/file.php?f...





I'll be thankful if someone could help me out of this !

Problem with a Linux program under Cygwin?
I can not really help, but maybe it would be useful to post it on a cygwin mailing list.


Saturday, May 22, 2010

Text messaging in Linux?

I'd like to try the new text messaging from mail feature. I'm using Linux with various Firefox browsers (1.5, 2.0, etc). When I click on the "Compose" drop-down, I only see "Email message (n)" or "Chat (c)".





The help says I should see a "Text (t)" option as well. Why don't I?

Text messaging in Linux?
You can use a website like this one...


http://www.killsometime.com/TextMessage....





But the easiest thing that I have found is to send an email to the phone which appears as a text message. Most of the phone companies have a site which will receive/resend for that reason.


http://www.email-unlimited.com/stuff/sen...
Reply:you need to be more clear. You're in an email program or what? there is intstant messaging software for linux.

aster

Writing programs for Linux?

Hi, say I have a program in standard C++, and it runs on the PC and Mac currently, but I want it to run on Linux as well, how do I decide on a distro to test it on? what distro do I compile it on? I don't want to install 50 distros on a pc just to make sure it works, any help?

Writing programs for Linux?
So, the question you are asking is how to do I run a C++ Windows executable on a Linux machine.





There are several ways to think about this.





1. If you have the C++ source code, you can copy the source files onto the Linux machine and compile it yourself. For example, you can use g++ on Linux (it is free) to compile C++ code.





2. If you don't have the source code, see if the program comes with a binary for linux





3. If you can't do that. You can install a windows emulator on the Linux machine. Then you can run window programs. Here is a link for such an emulator - http://www.winehq.org/





Have fun.
Reply:The distro won't matter because they'll all come with the same gnu compiler.





A distro is nothing more than a "branded" version of GNU/Linux.





The Data Analyst - http://www.squidoo.com/thedataanalyst
Reply:looks like ubuntu is the winner and the opensuse the 2nd :)
Reply:-- QUOTE --


Hi, say I have a program in standard C++, and it runs on the PC and Mac currently, but I want it to run on Linux as well,


-- END Q --





If it is standard C++, it will work on Linux as well.





-- QUOTE --


how do I decide on a distro to test it on?


-- END Q --





Doesn't matter. All of them are Linux. Good bet it will work on other Unices as well.





-- QUOTE --


I don't want to install 50 distros on a pc just to make sure it works, any help?


-- END Q --





Just test your programs on _something_. It really doesn't matter which one. They are all Linuxen.





-- QUOTE --


How do I compile my programs for distribution onto the Linux platform?


-- END Q --





You know it's easier _not_ to compile, right? Source tarballs are a common form of distribution, and anyone can do a ./configure make make install sequence. So basically look up how to create configure and makefiles. That will tell you how to setup ./configure make for your project. Almost everyone on Linux has the tools needed for the compile (gcc and libraries). So they will typically do ./configure make make install.





Compiling is a bit tricker. Actually, typically, you don't just compile, but also distribute in the appropriate package management solution. Google up the entire process as it is a bit more involved. It's also distribution specific. Example: All debian based Linux distros use apt. suSE has YAST. There's RPMs, typically associated with Fedora and a few others.
Reply:When I downloaded Ubuntu it didn't have a C complier (gcc)on the LiveCD, I had to download it separately.





I would download PCLinuxOS because at I know that is more likely to include a complier with the LiveCD.


What do I do with Linux?

I heard that programmers use Linux for programming and compiling. First, Why do they have to use Linux?


Second, Could you tell me the difference between a good compiler and a bad one?


Third, I know how to program with C++ and I am going to learn Java and Python. Any suggestion?


Fourth, What kind of programs do Programmers use?


Thanks

What do I do with Linux?
Nobody HAS to use Linux. That's the beauty of it. They use it because it is fun to tinker with, they can mess with the code if they want, they can improve upon it, and it is free.
Reply:I can only speak for myself, but I prefer to program in linux because I prefer the text editor emacs over any text editor out. I have more control over the editor than I do with any other text editor out there plus it lines up everything for me so I dont have to push "tab" a thousand times when I'm writing code.





Most people who use linux do so because it is command line based as opposed to a GUI, such as windows. Most hard core programmers prefer to type out what they are doing rather than using some jazzed up window, that may or may not work depending on how the operating system feels at the moment.





The difference between a good and bad compiler is a matter of opinion. For example, for me I prefer jdg in linux for debuging JAVA programs where others may prefer using something like Eclipse to debug their JAVA code.





If you are going to learn JAVA and you already know c++ then you should have no problem picking up JAVA.





Again, I can only speak for myself on what programs I use (and I assume you mean for programming). I simply use emacs for just about everything, and of course the debuggers and compilers.
Reply:Below link could answer why linux ?





I don't think there is something called good %26amp; bad for compilers....Well each programmers use compilers based on his programming language....





Good, learning java...could be best idea....you can also learn java web service along with it. Python could b useful for web propgramming too...





Its upto programmer %26amp; based on the requirement of application he is wrtting.


How do I install software on Linux.?

First of all, I'm new to Linux but not stupid (I hope).





Now, I've installed openSUSE in the past and always have the same problem when installing software. I can never find all the dependencies to install one simple program. For example:





If I want to install Program A, it needs Program B first. But Program B needs Program C. But Program C needs Library X. But Library X needs Compiler Z, etc etc etc. And then I forget what I was trying to install in the first place.





Does anybody else have this problem? Or am I doing something VERY wrong?

How do I install software on Linux.?
Normally, if you use for example YaST for installing your software. This is one of the advantages of the RPM files, which is used by openSUSE. But it depends where and how you get your software. If you use YaST for downloading your software from the repositories, it will resolve the dependencies automatically. It's the same with downloaded RPM files from a website. But if you get TAR.GZ or TAR.BZ2 files (source code), which need to be compiled, there could be some problems. So until you cannot avoid it, use the repositories or use the RPM files. If encounter again problems, please specifiy your program.





Using YaST is mainly self-explaining - start the dialog to install the software and search for it. For RPM files a double-click should be fine. If you want to use the terminal, you can use zypper, whose use is explained here: http://en.opensuse.org/Using_zypper





For the TAR.GZ files: Extract them with a double click, open the terminal, switch with using "cd" to the directory of the extracted files, type "su" and your password (for getting admin rights), and use "sh ./configure" or something like this. There could also be a file called INSTALL... after having used this, type "make" and then "make install". But it's not always the same so that you should read the README before.





As you can see RPM files are a lot easier to use...





Regards.
Reply:It depends how you are installing the software. Generally the best way to install software on linux is to use some software getting method. You can install the SUSE version of "apt". Then you can command line "apt-get install xxxx" and it will install that piece of software as well as all its dependancies.


Where do I find source code of linux commands?

Linux commands like cp, dir, ls, shred, man (etc...) are nothing but programs (hopefully all written in C). I would really like to know exactly how they work (and make a few modifications to some) so I need their source code...


Can you tell me where to find source code of linux commands?


Thank you in advance!

Where do I find source code of linux commands?
In general there are several places you can go to get the source for these commands. This is mostly because there can be several different implementations of the commands.





1) The company who distributed your version of Linux. Most versions of these types of commands are under the GPL and as such the person or company who gave you the executable has to make a copy of the source code available to you. Usually these are released as source rpms, and some times come on one of the CDs or DVDs that you used to install Linux with. You can often find them on the web too.





For example the RHEL5 Server source rpm (SRPM) is


ftp://ftp.redhat.com/pub/redhat/linux/en...





Most of the time your distribution will have a tool like yum to install these and other rpms for you.





2) www.gnu.org


GNU probably wrote the commands that are on your distribution of Linux, although a few very specialized distros use different implementations of the commands (Usually busybox http://www.busybox.net/ but this is really rare).





http://www.gnu.org/software/coreutils/


has instructions on how to download a very recent copy of the code, which may be much much newer then the version currently installed on your computer.





NOTE:





Some shells, like tcsh and csh have their own implementations of these commands built into them. This is because it is faster to run the command as part of your shell then to fork and exec a new command. So if you do change them be sure to check that you are actually running your updated version. BASH usually does not play these games but you can always check by running which followed by the name of your command.

marigold