Re: Checking if the X Server is running
--- Holger Krull ha scritto: Holger Krull schrieb: Holger Krull schrieb: I was to fast on my last email. I tested it now: You need (on windows): set DISPLAY=127.0.0.1:0.0 c:\cygwin\bin\bash.exe -l /home/krull/test.sh (it is important that there is no space between 0.0 and ) test.sh: #!/bin/sh ps |grep -i /xwin /dev/null if [ $? -eq 0 ] then xterm -e /usr/bin/bash -l else run XWin :2 -multiwindow -clipboard -silent-dup-error that :2 is from my testing, sorry, doesn't belong there xterm -e /usr/bin/bash -l fi Thanks Holger. Now this works perfectly. It does open up a Windows cmd window which remains open until I finish with my app but I can live with that. Thanks Phil Betts I think now the checkX script also works. I think my mistake was I was leaving a space between set DISPLAY=127.0.0.1:0.0 and - Thankfully Holger pointed this out. O.O. ___ L'email della prossima generazione? Puoi averla con la nuova Yahoo! Mail: http://it.docs.yahoo.com/nowyoucan.html -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/
Re: Checking if the X Server is running
As someone pointed out in another post the sequence ps |grep has a risk of finding grep itself in the list. The command pgrep combines both and hasn't that risk. Thanks Holger. Now this works perfectly. It does open up a Windows cmd window – which remains open until I finish with my app – but I can live with that. That can be avoided by dual nested start like: C:\cygwin\bin\bash.exe -c -l 'run bash -c -l Xwin.exe :0 -query 192.168.11.1 -once ' The first bash closes after the command and so does the cmd window which started it. The at the end is important to get a independend process. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/
Re: Checking if the X Server is running
On Mon, Oct 01, 2007 at 05:33:12PM +0100, Phil Betts wrote: It's probably not the cause of your problem, but you should never use ps | grep xxx to detect if a process is running. This is because the grep process will (sometimes) detect itself and give you a false positive, and your xterm will try to start when there is no server running. A just a random snippet that I find useful for preventing just that: ps | grep xterm matches itself, since the command line contains 'xterm'. ps | grep '[x]term' doesn't match itself, since the command line no longer contains the string 'xterm'. It's more portable than pgrep xterm and it's less ugly than ps | grep xterm | grep -v grep So it's what I usually find myself using. ~Matt -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/
RE: Checking if the X Server is running
[EMAIL PROTECTED] wrote on Tuesday, October 02, 2007 4:21 PM: On Mon, Oct 01, 2007 at 05:33:12PM +0100, Phil Betts wrote: It's probably not the cause of your problem, but you should never use ps | grep xxx to detect if a process is running. This is because the grep process will (sometimes) detect itself and give you a false positive, and your xterm will try to start when there is no server running. A just a random snippet that I find useful for preventing just that: ps | grep xterm matches itself, since the command line contains 'xterm'. ps | grep '[x]term' doesn't match itself, since the command line no longer contains the string 'xterm'. It's more portable than pgrep xterm and it's less ugly than ps | grep xterm | grep -v grep So it's what I usually find myself using. pidof XWin - Jörg -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/
Re: Checking if the X Server is running
--- Holger Krull ha scritto: As someone pointed out in another post the sequence ps |grep has a risk of finding grep itself in the list. The command pgrep combines both and hasn't that risk. Thanks for this tip. That can be avoided by dual nested start like: C:\cygwin\bin\bash.exe -c -l 'run bash -c -l Xwin.exe :0 -query 192.168.11.1 -once ' The first bash closes after the command and so does the cmd window which started it. The at the end is important to get a independend process. I dont think I managed to get this to work. This seems to open a single big window for cygwin which is not want I wanted. So I then went in and added the multiwindow flag. With this, I again got that error i.e. error dialog. I actually want to find a way to execute graphical applications by this method. So with this method even if we succeed, would not allow me to start up a graphical application. So I went ahead and edited this so that it runs a shell script instead of XWin.exe however with that I either get the error dialog, or nothing works. O.O. ___ L'email della prossima generazione? Puoi averla con la nuova Yahoo! Mail: http://it.docs.yahoo.com/nowyoucan.html -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/
Cygwin/X remote desktop
Hello, I am new bee here. I am using Cygwin/X from my windows XP box to connect to my development linux system via SSH X-port-forwarding. When I remote desktop to windows XP, all the X windows slow down heavily. How do I fix this issue? Thanks, Jeeva -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://x.cygwin.com/docs/ FAQ: http://x.cygwin.com/docs/faq/
completely fresh reinstall of cygwin?
I originally installed cygwin on a network drive (p:\cygwin). Due to various intermittent network problems I wanted to move the install it to my local c:\ (e.g. c:\cygwin) so that it is no longer network dependent. Unfortunately when I tried to put a new install into c:\cygwin, the /usr/bin and /usr/lib directories still point to my p:\cygwin\ install. I tried deleting the registry keys HKEY_CURRENT_USER and HKEY_CURRENT_MACHINE 'Software/Cygnus Solutions' and reinstalling, but mount still the directories pointing to p:\cygwin\ How can I get a fresh, independent install on my local c:\ ? -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Can cron cause computer to wake up from hibernate?
Some time ago, it happened to me that my PC came out of hibernate without no apparent reason. Initially I though that someone, accidentally, hit the keyboard causing the resume of the PC, but after disabling keyboard switch on, the problem persisted. I then discovered that my network card was configured to wake up the PC when receiving certain kind of packets. Disabling that feature did the job. Ciao, Danilo Saurabh Tendulkar wrote: Hi, I'm trying to troubleshoot why my pc comes out of hibernate. It seems like some of the times this happens correspond to cron jobs. Is it possible that cron could be (one of) the culprit(s) here? If so, is there a way to prevent cron from waking up the computer? Thank you. saurabh _ Express yourself instantly with MSN Messenger! Download today it's FREE! http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/ -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
RE: Re: Can cron cause computer to wake up from hibernate?
Saurabh Tendulkar wrote: Hi, I'm trying to troubleshoot why my pc comes out of hibernate. It seems like some of the times this happens correspond to cron jobs. Is it possible that cron could be (one of) the culprit(s) here? If so, is there a way to prevent cron from waking up the computer? Thank you. saurabh Danilo Turina wrote on Tuesday, October 02, 2007 3:50 AM: Some time ago, it happened to me that my PC came out of hibernate without no apparent reason. Initially I though that someone, accidentally, hit the keyboard causing the resume of the PC, but after disabling keyboard switch on, the problem persisted. I then discovered that my network card was configured to wake up the PC when receiving certain kind of packets. Disabling that feature did the job. Many BIOSs can wake up the computer at specific times. I'm not sure, but I seem to remember having had a BIOS that that mentioned something like waking up when receiving something from the network, so you might also look for that. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Updating Cygwin and packages
Greg Chicares gchicares at sbcglobal.net writes: On 2007-10-01 06:24Z, D wrote: When I downloaded and installed cygwin I had installed various packages. I was wondering how do I go about updating those packages and cygwin for that matter if possible. Run 'setup.exe' again. Greg, is there a command line way to do this? like port upgrade outdated, yum upgrade or emerge world? Thanks André -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
RE: Re: Updating Cygwin and packages
Andre Bonhote wrote on Tuesday, October 02, 2007 7:38 AM: Greg Chicares gchicares at sbcglobal.net writes: On 2007-10-01 06:24Z, D wrote: When I downloaded and installed cygwin I had installed various packages. I was wondering how do I go about updating those packages and cygwin for that matter if possible. Run 'setup.exe' again. Greg, is there a command line way to do this? like port upgrade outdated, yum upgrade or emerge world? The FAQ is your friend: http://cygwin.com/faq/faq.setup.html#faq.setup.cli
Re: llrint implementation in Cygwin
Charles Wilson wrote: Diego Biurrun wrote: Next time you call shenanigans, get your facts straight first please. I never claimed that we do not *have* OS-specific workarounds, I said we do not *add* them. That's a vey fine distinction and was not at all clear from the foregoing conversation. Maybe I was not terribly clear nor explicit. That does not preclude you from stating your points a little more, umm, defensively, does it? The libavcodec directory has entirely separate subdirs for different processors -- platform specificity is BUILT IN to the ffmpeg source tree. Nonsense. These are assembler optimizations for speed-critical functions (and the reason why you can watch movies without GHz CPUs). These are, by their very nature, processor-specific, but they are not workarounds. Nothing could be further from the truth. It's an example of special purpose (blocks of) code, where a given block is compiled only under particular circumstances -- e.g. for a specific target cpu -- in pursuit of a particular goal. In this case: speed. Control flow (whether a particular file or block of code is actually compiled for a given target) is determined by...for lack of a better term, makefile magic. No, I'm not letting you off the hook here, you are still talking nonsense. That file ALSO contains a half-dozen implementations of read_time depending on which microprocessor architecture is in use. What does this have to do with a workaround? read_time is internally used in some benchmarking macros, it is not an OS function. It's an exampleof special purpose (blocks of) code, where a given block is compiled only under particular circumstances -- e.g. for a specific target cpu -- in pursuit of a particular goal. In this case: high res benchmarking. Control flow (whether a particular file or block of code is actually compiled for a given target) is determined by...using the earlier nomenclature, ifdef magic. .. and nonsense again .. What are you going to claim next? That something like if ( condition ) block of code else block of alternative code is an example of special purpose (blocks of) code where given block is run only under particular circumstances in pursuit of a particular goal using control flow magic? Oh, and lookee here, in the same file: #ifndef HAVE_LRINTF /* XXX: add ISOC specific test to avoid specific BSD testing. */ /* better than nothing implementation. */ /* btw, rintf() is existing on fbsd too -- alex */ static av_always_inline long int lrintf(float x) { return (int)(rint(x)); } #endif /* HAVE_LRINTF */ Good catch, this is cruft from ages ago. I will look into nuking this very soon. So, I find an example of EXACTLY the sort of feature-dependent workaround under discussion, and your response is no, that's not a valid example...and if it is, we'll get rid of it? You have an interesting way of twisting words. I say good catch and you translate this to no, that's not a valid example. It's doubly interesting that I admit you are right and you turn this around into me being in denial while at the same time you are in denial about the points where I proved you wrong. Look, the point is: there are many platforms out there that do not support the entire panoply of C99 functions. Or even all POSIX (1b? 1c? 1e? 2?) functions. Yes. And if every program out there tries to be portable to those platforms by adding workarounds to their codebase we will soon have terabytes of cruft and bugs all over the place. Then again, if just one of them goes to the length of patching upstream instead of hacking their code, all those programs will suddenly work on that platform. Short term pain, long term gain, it boils down to nothing more than that... If the FFMpeg team cares about portability, the correct answer is not to climb upon a high horse, declaim we do not [use|add] platform-specific workarounds and deliberately release code that is /not/ portable to the disdained platform -- and then blame that platform for not updating their runtime library according to /your/ project's release schedule. Well, cygwin will just have to be broken You are (again) putting words into my mouth and twisting what I said. I never - expressed disdain for Cygwin nor - blamed Cygwin for not updating their runtime library nor - forced our release schedule on anybody. I merely enquired whether - an implementation of llrint was in the works and - when it would hit mainstream Cygwin. This was done so that I could add an appropriate comment into the release notes about the status of Cygwin support. Heck, if the answer had been something along the lines of We'll have it next month or similar, we might even have delayed *our* release to accomodate this. Now if somebody inquires about the status of Cygwin compilation I can advise them to either (in order of preference) - patch newlib or - upgrade their gcc somehow or - wait for
Re: Re: Updating Cygwin and packages
Buchbinder, Barry (NIH/NIAID) [E] BBuchbinder at niaid.nih.gov writes: The FAQ is your friend: http://cygwin.com/faq/faq.setup.html#faq.setup.cli Ah, what a n00b I am :-) Thanks a lot! André -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: completely fresh reinstall of cygwin?
Andy Foster wrote: I originally installed cygwin on a network drive (p:\cygwin). Due to various intermittent network problems I wanted to move the install it to my local c:\ (e.g. c:\cygwin) so that it is no longer network dependent. Unfortunately when I tried to put a new install into c:\cygwin, the /usr/bin and /usr/lib directories still point to my p:\cygwin\ install. I tried deleting the registry keys HKEY_CURRENT_USER and HKEY_CURRENT_MACHINE 'Software/Cygnus Solutions' and reinstalling, but mount still the directories pointing to p:\cygwin\ Don't go looking for solutions in the registry. Use mount. How can I get a fresh, independent install on my local c:\ ? You can rerun setup.exe and _specify_the_new_Cygwin_root_. -- Larry Hall http://www.rfk.com RFK Partners, Inc. (508) 893-9779 - RFK Office 216 Dalton Rd. (508) 893-9889 - FAX Holliston, MA 01746 _ A: Yes. Q: Are you sure? A: Because it reverses the logical flow of conversation. Q: Why is top posting annoying in email? -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Why I cannot build my own program in Cygwin when using libpng function????
Hi, I installed libpng in cygwin. then I include png.h in my files, and use many fucntions provided by libpng. But when I compile it, it reports: [EMAIL PROTECTED] ~/Desktop//pix $ gcc -lpng12 -lz -I/usr/include/libpng12 -o ref ref.c /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x37): undefined reference to `_ png_check_sig' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x6b): undefined reference to `_ png_create_read_struct' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c: (.text+0x92): undefined reference to `_ png_create_info_struct' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0xbc): undefined reference to `_ png_destroy_read_struct' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0xf5): undefined reference to `_ png_destroy_read_struct' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x115): undefined reference to ` _png_init_io' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x12a): undefined reference to ` _png_set_sig_bytes' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x140): undefined reference to ` _png_read_info' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x18e): undefined reference to ` _png_get_IHDR' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x1e3): undefined reference to ` _png_destroy_read_struct' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x20d): undefined reference to ` _png_get_valid' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x23a): undefined reference to ` _png_get_bKGD' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x397): undefined reference to ` _png_destroy_read_struct' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x3b9): undefined reference to ` _png_set_palette_to_rgb' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x3d8): undefined reference to ` _png_set_gray_1_2_4_to_8' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x3f6): undefined reference to ` _png_get_valid' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x407): undefined reference to ` _png_set_tRNS_to_alpha' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x41d): undefined reference to ` _png_set_strip_16' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x433): undefined reference to ` _png_set_packing' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x45a): undefined reference to ` _png_set_gray_to_rgb' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x49e): undefined reference to ` _png_set_rgb_to_gray_fixed' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x4b4): undefined reference to ` _png_read_update_info' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x4cd): undefined reference to ` _png_get_rowbytes' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x4ee): undefined reference to ` _png_get_channels' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x52f): undefined reference to ` _png_destroy_read_struct' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x570): undefined reference to ` _png_destroy_read_struct' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x5da): undefined reference to ` _png_read_image' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x601): undefined reference to ` _png_read_end' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x66c): undefined reference to ` _png_destroy_read_struct' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x6d5): undefined reference to ` _display_depth' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x6fa): undefined reference to ` _display_depth' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o:ref.c:(.text+0x709): undefined reference to ` _display_depth' /cygdrive/c/DOCUME~1/xiaodwan/LOCALS~1/Temp/ccsDlvm3.o: ref.c:(.text+0x769): undefined reference to ` _display_graphics' /usr/lib/gcc/i686-pc-cygwin/3.4.4/../../../libcygwin.a(libcmain.o):libcmain.c:(.text+0xab): undefine d reference to [EMAIL PROTECTED]' collect2: ld returned 1 exit status I also tried many many other flags in gcc, like -lm,. -lpng, -static, I always got these errors. The same problems exist when I compile my own codes when I using pixbuf library. I want to cry. any one can help me? Thanks so much!!! Xiaodong -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Why I cannot build my own program in Cygwin when using libpng function????
valpassing wrote: I installed libpng in cygwin. then I include png.h in my files, and use many fucntions provided by libpng. But when I compile it, it reports: [EMAIL PROTECTED] ~/Desktop//pix $ gcc -lpng12 -lz -I/usr/include/libpng12 -o ref ref.c try gcc -I/usr/include/libpng12 -o ref ref.c -lpng12 -lz gcc searches from left to right. If ref.c uses symbols provided by libpng, then libpng must appear *after* ref.c on the command line. -- Chuck -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Can cron cause computer to wake up from hibernate?
Danilo Turina wrote: Some time ago, it happened to me that my PC came out of hibernate without no apparent reason. Initially I though that someone, accidentally, hit the keyboard causing the resume of the PC, but after disabling keyboard switch on, the problem persisted. I then discovered that my network card was configured to wake up the PC when receiving certain kind of packets. Disabling that feature did the job. Ciao, Danilo AFAICT that's not hibernation - that's sleep mode. There's a difference, hence the different terms. Hibernation mode involves placing the current contents of memory in swap and shutdown off, not down, the computer. It requires that you push the power button to start the boot up sequence. During boot up the computer notices that it was hibernating and says *Resuming* Windows not *Starting* Windows. Main memory is then taken from virtual memory and loaded into main memory and control is transfered to the scheduler. I use hibernate mode all the time. I once used it at work when we were moving from one building to another. During that time the computer was not even connected to the power source and indeed in a moving truck! When at the new building I powered it on and it came back exactly to where I had left it off prior to hibernating it. I don't think that that is what happened to you, rather I think that you were in sleep mode and the network card awoke your computer. Sleep mode can be gotten out of without having to press the power button and is nearly instantaneous. -- Andrew DeFaria http://defaria.com Why is a man who invests all your money called a broker? -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Home directory
Larry Hall (Cygwin reply-to-list-only-lh at cygwin.com writes: Gmane User wrote: ...it might be worthwhile to uninstall cygwin, then reinstall it on a secondary IDE drive (not drive c:), along with the cygwin user file/folder tree. It has a lot more space, so I can forget the network drive altogether. I was initially trying to avoid the secondary drive because I fully expect suprises and a brand new learning experiences due to the unconventional location. But I can always give it a go. The only issue at hand is time. There's no reason to fear this. I have all sorts of Cygwin installation where the root drive is not C:. It works just fine. Er...fear? _Concern_. Not a trivial amount of it, granted. Thanks for assuaging that -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Can cron cause computer to wake up from hibernate?
On Tue, Oct 02, 2007 at 08:51:19AM -0700, Andrew DeFaria wrote: Danilo Turina wrote: I then discovered that my network card was configured to wake up the PC when receiving certain kind of packets. Disabling that feature did the job. AFAICT that's not hibernation - that's sleep mode. There's a difference, ... I use hibernate mode all the time. I once used it at work when we were moving from one building to another. During that time the computer was not even connected to the power source and indeed in a moving truck! When at the new building I powered it on and it came back exactly to where I had left it off prior to hibernating it. Hibernation does involve swapping everything in memory to disk, freezing the state of all processes, and powering down the system. But, the system being powered down does not mean that no part of the system is receiving power. In fact, Wake On LAN technology is designed to work on machines that are completely shut down - the only caveat is that the motherboard reserves power for the network card, and the network card scans for a particular magic packet addressed to it. If that packet shows up, the computer turns itself back on. So, not only can this bring a computer out of sleep or hibernation, it can bring a computer out of a shutdown, too, as long as the device is still plugged in. ~Matt Wozniski -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Home directory
Paul McFerrin wrote: Gmain User wrote: Larry Hall (Cygwin reply-to-list-only-lh at cygwin.com writes: [lines deleted] There's no reason to fear this. I have all sorts of Cygwin installation where the root drive is not C:. It works just fine. Larry Hall: When having multiple copies of Cygwin installed on your hard drive, how do you handle the issue of mounts? With mounts being handled thru the registry, how can you handle multiple and completely different set of mounts and not affect the other instances of Cygwin? Or maybe you are referring to multiple installations on different machines. I was actually just referring to having more than 1 machine with a Cygwin installation that isn't rooted under C:. Doing this works fine. There is, of course, a concern if you're going to keep two separate installs of Cygwin on the same machine. This isn't recommended but can handled by a script that changes your path and mounts to point to one installation or the other. Of course, this means you should not be running anything from one install when switching to the other (or after switching either). It's worth noting that it's extremely rare to _need_ to keep two versions of Cygwin around for active use. Those who may find themselves with such a need are encouraged to report the problem to the list so a resolution can be found. The alternative is being forever stranded in the past, which isn't a big help to anyone. Oh and keeping two version of Cygwin around means you have an unsupported configuration so you're on your own when problems do pop up. Not a nice place to be. ;-) -- Larry Hall http://www.rfk.com RFK Partners, Inc. (508) 893-9779 - RFK Office 216 Dalton Rd. (508) 893-9889 - FAX Holliston, MA 01746 _ A: Yes. Q: Are you sure? A: Because it reverses the logical flow of conversation. Q: Why is top posting annoying in email? -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Keeping setup.exe from touching mount entries
Is there a way to prevent setup from touching the existing mount table entries in the registry? I would like to create 'another' instance of Cygwin for my own customizations and not affect my original instance. Yes, I only have one PC available to me. - paul mcferrin -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Huge memory leak, probably related to making new processes
Try executing: find -exec echo {} \; Simple command. This one, however, leaks at about 5kB/s. I tried the following: find|xargs echo This one didn't appear to leak, but then I tried this one: find|xargs -n 1 echo This also leaked at around the same rate. Then I tried the following: COUNTER=1 while [ $COUNTER -lt 123456 ]; do echo $COUNTER; let COUNTER=$COUNTER+1; done This one did not leak, making me believe that this is related to new process execution. I tried this: COUNTER=1 while [ $COUNTER -lt 123456 ]; do (echo $COUNTER); let COUNTER=$COUNTER+1; done and it started leaking pretty fast (maybe 4kB/s). I searched for this, but I couldn't find anything useful (or I couldn't find any good search queries). A few questions: - Is this a bug or am I just wrong in part or the whole of the above? - If so, is there a way to prevent or circumvent this? - Again, if it is a bug, is there a way to free this memory somehow without restarting the computer (or anything involving closing all/majority of applications, like logout)? It appears that no process owns this memory, but it is disappearing (i.e. true leak), so a simple taskkill is not a solution. -- View this message in context: http://www.nabble.com/Huge-memory-leak%2C-probably-related-to-making-new-processes-tf4557470.html#a13006193 Sent from the Cygwin Users mailing list archive at Nabble.com. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Home directory
Andrew DeFaria Andrew at DeFaria.com writes: Gmain User wrote: Andrew DeFaria wrote: Personally I'd: $ mv /home /home.save $ mount -bsf //server/homeshare /home $ mv -rp /home.save/* /home Adjust the output of /etc/passwd to use /home/$USER That places all cygwin file trees for all user accounts (including administrators) onto my own domain network file space. Yes, isn't it wonderful! Now everybody can log into anybody's machine and feel right at home (pardon the pun). And people's desktops can actually be used at night to assist with nighttime processing like builds and the like - just like if you had a bunch of Linux or Unix boxes. Now imagine that! Except that network file space with which I am provided is account specific i.e. for myself only. I suspect that it isn't what I'm seeking to realize, though it is an interesting way to migrate account file trees. If you are that concerned about eveybodys home directory being mounted do this instead: $ mv /home/$USER /home/$USER.save $ mount -bsf //server/myhomeshare /home/$USER $ mv -p /home/$USER/save/* /home/$USER Of course. Good way to make the network file space appear the same as a conventional cygwin installation. Thanks. Now it's really a matter of deciding whether to work off the network file space by default. It offers mobility, but also vulnerability to network issues. Some pondering is due. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Keeping setup.exe from touching mount entries
Paul McFerrin wrote: Is there a way to prevent setup from touching the existing mount table entries in the registry? I would like to create 'another' instance of Cygwin for my own customizations and not affect my original instance. Yes, I only have one PC available to me. No but you can restore the old mount table entries with 'mount'. Before you start, do mount -m mntentries.bat. Now install to where you want another version. Afterwards, before you start/restart any Cygwin proggie, run mntentries.bat from cmd.exe. That will restore what you had before the second installation. If you want to keep around the mount points for the second installation, make a backup of those the same way. Good luck! -- Larry Hall http://www.rfk.com RFK Partners, Inc. (508) 893-9779 - RFK Office 216 Dalton Rd. (508) 893-9889 - FAX Holliston, MA 01746 _ A: Yes. Q: Are you sure? A: Because it reverses the logical flow of conversation. Q: Why is top posting annoying in email? -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Huge memory leak, probably related to making new processes
wimxa wrote: Try executing: find -exec echo {} \; Simple command. This one, however, leaks at about 5kB/s. I tried the following: How do you know it is leaking memory? If you are looking at Windows Task Manager or some similar program, then you're probably just being misled. The OS will automatically free the memory from each echo process after it terminates, but it may not always immediately report it as available. -Lewis -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: completely fresh reinstall of cygwin?
How can I get a fresh, independent install on my local c:\? You can rerun setup.exe and _specify_the_new_Cygwin_root_. Annoyingly, I find that this useful recovery of an un-mounted system is a function that the current setup v.2.573.2.2 fails to do, that the earlier long-running v.2.510.2.2 always managed. If a user becomes un-mounted for whatever reason (maybe by accident or maybe by design) then the old 2.510.2.2 could be relied upon to read /etc/setup/installed.db and if appropriate re-mount the user without downloading or installing anything. But 2.573.2.2 either does not read or does not understand /etc/setup/installed.db and will try to re-mount the user only by downloading and installing everything from scratch. I fear there will come a time when I lose some important new functionality, but for the moment I am still only using 2.510.2.2 for all system management, for this reason. Fergus -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Can cron cause computer to wake up from hibernate?
On Tue, Oct 02, 2007 at 08:51:19AM -0700, Andrew DeFaria wrote: Danilo Turina wrote: I then discovered that my network card was configured to wake up the PC when receiving certain kind of packets. Disabling that feature did the job. AFAICT that's not hibernation - that's sleep mode. There's a difference, I use hibernate mode all the time. I once used it at work when we were moving from one building to another. During that time the computer was not even connected to the power source and indeed in a moving truck! When at the new building I powered it on and it came back exactly to where I had left it off prior to hibernating it. In fact, Wake On LAN technology is designed to work on machines that are completely shut down - the only caveat is that the motherboard reserves power for the network card, and the network card scans for a particular magic packet addressed to it. If that packet shows up, the computer turns itself back on. ~Matt Wozniski Oh it is definitely hibernate. I have never had the computer come out of shutdown though. I found partial answers here (http://support.intel.com/support/network/sb/cs-008459.htm) and here (http://groups.google.com/group/alt.comp.periphs.mainboard.abit/msg/c40efb06dce495d6). My computer does show ACPI. I'll try turning off my cable modem and see if it works. Thanks for the suggestions. saurabh _ FREE pop-up blocking with the new MSN Toolbar - get it now! http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/ -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Home directory
Gmain User wrote: Thanks, Brian. I was actually asking in the context of not updating cygwin right away. Whether or not one could access up-to-date accumulation of release notes, possibly on the web. Cygwin doesn't have monolithic releases. Every individual package is on its own release schedule. It's meaningless to talk about release notes at a higher level than the package level, in the current scheme. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
installed packages?
I remember there is a command to query all the installed packages -- name and version. But I cannot find it anywhere. Can someone remind me of that command? Thanks, Peter -- View this message in context: http://www.nabble.com/installed-packages--tf4559057.html#a13010544 Sent from the Cygwin Users mailing list archive at Nabble.com. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
RE: installed packages?
From: peter360; Sent: Tuesday, October 02, 2007 8:01 PM I remember there is a command to query all the installed packages -- name and version. But I cannot find it anywhere. Can someone remind me of that command? cygcheck -cd -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Huge memory leak, probably related to making new processes
How do you know it is leaking memory? If you are looking at Windows Task Manager or some similar program, then you're probably just being misled. The OS will automatically free the memory from each echo process after it terminates, but it may not always immediately report it as available. -Lewis Yes, I am using Windows Task Manager. Actually, it is leaking. I discovered the leak when I had like 10 programs running when I started a simple find just like the ones I posted. I searched a big collection of files (several tens of MB). After a while, I noticed it still didn't finish (I expected it to be done at the time) and that my computer is behaving somewhat strangely. I started closing one program at the time, but that was quite slow and getting worse. Then I noticed that HDD led was on most of the time. I launched Task Manager and it showed that my memory is 15MB (on a 2GB machine). I was assuming (with the programs launched) that around 1GB or so would be free - well, it was not. I restarted the machine, ~1.5GB free. All after that is history (i.e. I performed the tests from my previous post and I got the offender). Does this sound as a reasonable test to you? Anyway, can I ask you to do this yourself - just do the last test: COUNTER=1 while [ $COUNTER -lt 123456 ]; do (echo $COUNTER); let COUNTER=$COUNTER+1; done and wait a little (couple of minutes). If necessary, repeat it until your memory drops to 10-20 MB range and your HDD should start whining. Then close cygwin and wait 10 minutes. The memory is still occupied. I don't know when Windows would free it, but I did not get that behavior with any other program (e.g. try to open close Firefox or such - it will show a peak in both directions regarding memory and will do that almost immediately). Thanks for the note. -- View this message in context: http://www.nabble.com/Huge-memory-leak%2C-probably-related-to-making-new-processes-tf4557470.html#a13010714 Sent from the Cygwin Users mailing list archive at Nabble.com. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
[gdb] Data watchpoints in Windows weirdness. Call for testers.
Hi all, I'm looking over watchpoint support in gdb, and I see something quite weird here. It seems something/someone is messing with the debug registers. When a watchpoint is triggered, the Dr6 register should have a few bits set to tell the debugger which of the Dr[0-3] watchpoints triggered. It happens that on all my machines many times it doesn't. The single step debug event comes through, but the output of the GetThreadContext call with CONTEXT_DEBUG_REGISTERS shows Dr6 == 0. This is quite unexpected, I don't see this happening on Linux, and goes against every example of debug register usage on Windows I could find - they all expect Dr6 to be set. I suspected some app from TBLODA was messing up with GetThreadContext or the NT native equivalent NtGetThreadContext or some such, so I uninstalled all AV and anti-everything software on one of the machines and still the problems shows up. So, I bit the bullet and installed a Windows XP SP2 from scratch on a Virtual PC VM, installed Cygwin+gcc+gdb, nothing else, and still, the problem persists. By a long shot, Cygwin doesn't do anything funny like hooking GetThreadContext, does it? What's also funny is that I believed that watchpoints worked properly at some point, but now I'm not so sure. Maybe it is a specific to this Windows version I'm using. All my machines and the machines at work have XP SP2. I have a workaround to it, which basicaly lies to gdb telling it that every set watchpoint was hit, everytime. It works quite nicelly, with the only bad effect being a bit of (unnoticeable) unefficiency when a breakpoint is hit - gdb will have to compare the watched regions for changes - but that is getting into too much detail for this list. Perhaps you, gentle reader, could ease my pain, by confirming the behaviour on your machine. Attached is a simple test main.c file you could use. Here is a broken test run: gcc main.c -o main.exe -g3 -O0 /usr/bin/gdb main.exe GNU gdb 6.5.50.20060706-cvs (cygwin-special) Copyright (C) 2006 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type show copying to see the conditions. There is absolutely no warranty for GDB. Type show warranty for details. This GDB was configured as i686-pc-cygwin... (gdb) start Breakpoint 1 at 0x401050: file main.c, line 8. Starting program: /cygdrive/d/cegccsf/cegcc/cegcc/src/build-gdb_server_cygwin_submit/main.exe Loaded symbols for /cygdrive/c/WINDOWS/system32/ntdll.dll Loaded symbols for /cygdrive/c/WINDOWS/system32/kernel32.dll Loaded symbols for /usr/bin/cygwin1.dll Loaded symbols for /cygdrive/c/WINDOWS/system32/advapi32.dll Loaded symbols for /cygdrive/c/WINDOWS/system32/rpcrt4.dll main () at main.c:8 8 { (gdb) watch count Hardware watchpoint 2: count (gdb) display count 1: count = 0 (gdb) c Continuing. Program received signal SIGTRAP, Trace/breakpoint trap. main () at main.c:11 11printf (count %d\n, count); 1: count = 999 (gdb) c Continuing. Program received signal SIGTRAP, Trace/breakpoint trap. main () at main.c:16 16printf (count %d\n, count); 1: count = 1000 (gdb) c Continuing. Program received signal SIGTRAP, Trace/breakpoint trap. main () at main.c:18 18Sleep (1000); 1: count = 1001 (gdb) c Continuing. Hardware watchpoint 2: count Old value = 0 New value = 1002 main () at main.c:18 18Sleep (1000); 1: count = 1002 Notice that most of the times, gdb didn't display the Old value, and that when finally it does, it shows the wrong old value. Doing: set debug infrun 1 set debugevents 1 set debugexceptions 1 maint show-debug-regs 1 ... helps to see why: A bad run: main () at main.c:8 8 { (gdb) watch count Hardware watchpoint 2: count (gdb) c Continuing. infrun: proceed (addr=0x, signal=144, step=0) insert_watchpoint (addr=403010, len=4, type=data-write): CONTROL (DR7): 000d0101 STATUS (DR6): DR0: addr=0x00403010, ref.count=1 DR1: addr=0x, ref.count=0 DR2: addr=0x, ref.count=0 DR3: addr=0x, ref.count=0 infrun: resume (step=0, signal=0) ContinueDebugEvent (cpid=4112, ctid=4740, DBG_CONTINUE); infrun: wait_for_inferior gdb: kernel event for pid=4112 tid=4740 code=EXCEPTION_DEBUG_EVENT) gdb: Target exception EXCEPTION_SINGLE_STEP at 0x00401085 infrun: infwait_normal_state infrun: TARGET_WAITKIND_STOPPED infrun: stop_pc = 0x401085 stopped_data_addr: CONTROL (DR7): 000d0101 STATUS (DR6): DR0: addr=0x00403010, ref.count=1 DR1: addr=0x, ref.count=0 DR2: addr=0x, ref.count=0 DR3: addr=0x, ref.count=0 infrun: random signal 5 ^^^ Program
Re: Home directory
Warren Young wrote: Gmain User wrote: Thanks, Brian. I was actually asking in the context of not updating cygwin right away. Whether or not one could access up-to-date accumulation of release notes, possibly on the web. Cygwin doesn't have monolithic releases. Every individual package is on its own release schedule. It's meaningless to talk about release notes at a higher level than the package level, in the current scheme. What you say makes perfect sense. The specific package I was referring to was coreutils. Unfortunately, the quoting containing the relevant thread details had to be trimmed because of the limit on quoting when posting through gmane, which was the case in some of my posts. Don't get me wrong, gmane is great, it's just a circumstance that needs to be pointed out as a factor contributing to this confusion. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: completely fresh reinstall of cygwin?
On Tue, Oct 02, 2007 at 11:28:25PM +0100, Fergus wrote: How can I get a fresh, independent install on my local c:\? You can rerun setup.exe and _specify_the_new_Cygwin_root_. Annoyingly, I find that this useful recovery of an un-mounted system is a function that the current setup v.2.573.2.2 fails to do, that the earlier long-running v.2.510.2.2 always managed. If a user becomes un-mounted for whatever reason (maybe by accident or maybe by design) then the old 2.510.2.2 could be relied upon to read /etc/setup/installed.db and if appropriate re-mount the user without downloading or installing anything. But 2.573.2.2 either does not read or does not understand /etc/setup/installed.db and will try to re-mount the user only by downloading and installing everything from scratch. I fear there will come a time when I lose some important new functionality, but for the moment I am still only using 2.510.2.2 for all system management, for this reason. Or, of course, you could just, you know, use mount. cgf -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Huge memory leak, probably related to making new processes
Anyway, can I ask you to do this yourself - just do the last test: COUNTER=1 while [ $COUNTER -lt 123456 ]; do (echo $COUNTER); let COUNTER=$COUNTER+1; done and wait a little (couple of minutes). If necessary, repeat it until your memory drops to 10-20 MB range and your HDD should start whining. Then close cygwin and wait 10 minutes. The memory is still occupied. I don't know when Windows would free it, but I did not get that behavior with any other program (e.g. try to open close Firefox or such - it will show a peak in both directions regarding memory and will do that almost immediately). Thanks for the note. I ran it for about 15 minutes, no problem. In general, you should be wary of what Task Manager is telling you. In this example, it doesn't make sense to me that memory could leak, because each of the (echo) processes is executing in a subshell, which terminates after completion. No matter what a process does in Windows, its memory is always returned when it terminates, unless it is doing something very unusual. (But, of course, cygwin's fork() does do something unusual...) You could try running some simple c++ program, after it looks like your memory is exhausted, to allocate 1 GB of memory, and see if it succeeds. When it returns, the OS will probably report more free memory. This was the basis of some scam-ish RAM cleaner programs that really didn't do anything other than make Task Manager's output look nicer. That said, you are also describing some real symptoms of a problem, such as exhausting the physical memory and swapping. That should not occur, so there may be some problem that's beyond my experience. (In your example, I would have said that maybe the disk thrashing you experienced was caused by find itself, but if you also see it just from running this subshell loop, that is strange.) I guess it could be something going wrong with fork(), etc, that someone else on the list might know about. They'll probably ask you to check all the usual suspects first... are there any firewalls, AV scanners, etc, running in the background? If so, try getting rid of all of them and see if the problem still occurs. There are some poorly written ones that have been known to interfere with cygwin. Hope that helps... -Lewis -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: Huge memory leak, probably related to making new processes
On Wed, Oct 03, 2007 at 04:20:18AM +, Lewis Hyatt wrote: Anyway, can I ask you to do this yourself - just do the last test: COUNTER=1 while [ $COUNTER -lt 123456 ]; do (echo $COUNTER); let COUNTER=$COUNTER+1; done and wait a little (couple of minutes). If necessary, repeat it until your memory drops to 10-20 MB range and your HDD should start whining. Then close cygwin and wait 10 minutes. The memory is still occupied. I don't know when Windows would free it, but I did not get that behavior with any other program (e.g. try to open close Firefox or such - it will show a peak in both directions regarding memory and will do that almost immediately). Thanks for the note. I ran it for about 15 minutes, no problem. In general, you should be wary of what Task Manager is telling you. In this example, it doesn't make sense to me that memory could leak, because each of the (echo) processes is executing in a subshell, which terminates after completion. No matter what a process does in Windows, its memory is always returned when it terminates, unless it is doing something very unusual. (But, of course, cygwin's fork() does do something unusual...) You could try running some simple c++ program, after it looks like your memory is exhausted, to allocate 1 GB of memory, and see if it succeeds. When it returns, the OS will probably report more free memory. This was the basis of some scam-ish RAM cleaner programs that really didn't do anything other than make Task Manager's output look nicer. That said, you are also describing some real symptoms of a problem, such as exhausting the physical memory and swapping. That should not occur, so there may be some problem that's beyond my experience. (In your example, I would have said that maybe the disk thrashing you experienced was caused by find itself, but if you also see it just from running this subshell loop, that is strange.) I guess it could be something going wrong with fork(), etc, that someone else on the list might know about. They'll probably ask you to check all the usual suspects first... are there any firewalls, AV scanners, etc, running in the background? If so, try getting rid of all of them and see if the problem still occurs. There are some poorly written ones that have been known to interfere with cygwin. Hope that helps... I've been waiting for someone to make the observation that Cygwin has no magic powers which allow it to allocate memory and never release it - even on process exit. No modern OS allows you to get away with that. If the OP is really seeing that then either there is something else on his system which is responsible for the behavior. The other alternative is misunderstanding of what is going on. I'd say that it was probably 50/59 which is the case here. cgf -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
Re: newbie question -- problem with launching shell script files
Alexey Illarionov wrote: I wrote a small script. Here is the content of the 'run.sh' #!/bin/sh cd /cygdrive/c Unfortunately, it does not work. The command './run.sh' does nothing. Let's back up a moment. What do you expect the above script to actually do? Nothing is the proper and expected behavior -- there is no way for a child process to change the CWD of the parent so if you are expecting the CWD to be different after running the script then you have a misunderstanding of how scripting works. If you want to affect things like the CWD or environment of the current process, you can't do it by invoking a child, you must source the contents of the script in the current process. Brian -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/