General :: GNU Find: Disable The Error When 'find' Finds No Matches
Aug 21, 2011
I've got a setup where I need to use 'find' to find 0 or more files in a certain directory, however, 'find' always produces an error when there are no files that match a certain check. Is it possible to run 'find' while having it omit errors when no files match the pattern?
View 2 Replies
ADVERTISEMENT
Aug 24, 2010
I'm not able to find a thread that matches my problem. It must be a software/hardware bug, because sound works normally on a 2nd computer running the same Debian version (lenny), and it also work on the 1st computer running Debian (squeeze). - In fact the sound was working on the 1st computer in one installation of Debian lenny, but not on a 2nd (same) installation on the same computer. - Given that I had fiddled with its settings (for a different reason), and couln't fix it, I decided that the software had now a bug, deleted everything on the partition and cloned the working Linux on it. It had the same problem, so old me thougth that I had a virus in the MBR and wrote zeros all over the H/D; I then checked that the MBR (512 bytes) consisted just of zeros, and reinstalled vista, Debian lenny and Debian squeeze on the totally clean drive. The problem is still there also on a 2nd lenny installation that I tried, but squeeze works well. It's possible that the lenny installation that was previously working, was doing so due to the magic of Debian-update, but I don't know. The guilty computer is a Compaq SR5760AN (mobo pegatron violet M2N78-LA) with nVidia 0774 chipset and realtek HDA integrated audio. If it's relevant, the DVD drive is HL-DT-ST DVD-RAM GH15L, video is Radeon HD3450, and CPU is AMD Phenom 9650 quad core.If I use alsaconf, it comes up with 'snd-hda-intel' but there seem not to be any intel chip on the machine, and squeeze works and lenny DID also work.
View 1 Replies
View Related
Jul 22, 2011
I am having issues with 3d I am trying to start up a game called auteria but it displays this error "Could not find a compatible opengl display resolution. Please check your driver configuration. (Error: Couldn't find a matching GLX visual)" I am on ubuntu 10.10 could anybody give me a solution on how to fix this issue?
View 5 Replies
View Related
Aug 10, 2011
Is there a non-root shell command that can tell me if a user's account is disabled or not? note that there is a fine distinction between LOCKING and DISABLED:
LOCKING is where you prepend ! or * or !! to the password field of the /etc/passwd file. On Linux systems that shadow the passwords, this marker flag may be placed in /etc/shadow instead of /etc/passwd. Password locking can be done (at a shell prompt) via password -l username (as root) to lock the account of username, and the use of the option -u will unlock it.
DISABLING an account is done by setting the expiration time of the user account to some point in the past. This can be done with chage -E 0 username, which sets the expiration date to 0 days after the Unix epoch. Setting it to -1 will disable the use of the expiration date.
The effect of locking to to prevent the login process from using a supplied password to hash correctly against the saved hash (by virtue of the fact that the pre-pended marker character(s) are not valid output character(s) for the hash, thus no possible input can ever be used to generate a hash that would match it). The effect of disabling is to prevent any process from using an account because the expiration date of the account has already passed.For my situation, the use of locking is not sufficient because a user might still be able to login, e.g. using ssh authentication tokens, and processes under that user can still spawn other processes. Thus, we have accounts that are enabled or disabled, not just locked. We already know how to disable and enable the account - it requires root access and the use of chage, as shown above.To repeat my question: is there a shell command which can be run without root privileges which can output the status of this account expiration info for a given user? this is intended for use on a Red Hat Enterprise 5.4 system.The output is being returned to a java process which can then parse the output as needed, or make use of the return code.
View 2 Replies
View Related
Sep 7, 2010
I have 4 Linux machines with cluster.My target is to find all kind of IP address (xxx.xxx.xxx.xxx) in every file in the linux system remark: need to scan each file in the linux system and verify if the file include IP address if yes need to print the IP as the following
more /etc/inet/file.example1
182.23.2.4
255.255.0.0
10.10.1.1
View 1 Replies
View Related
Sep 11, 2009
I am trying to do a find/grep/wc command to find matching files, print the filename and then the word count of a specific pattern per file. Here is my best (non-working) attempt so far:
wc `find . ( -name "*.as" -o -name "*.mxml" ) -exec grep -H HeightResizableList {}` ;
View 10 Replies
View Related
Jul 15, 2011
Is there a way to specify to find that I only want text files (and not binary files)? Grep has an option to exclude binary files, so I thought find probably has a similar feature, but I've been unable to find it.
View 2 Replies
View Related
Feb 28, 2011
I have used diff command in past.I faced a situation to which I did not had a cluehere are some text strings (which can be stored in a file)Quote:
CONFIG_XEN=y
CONFIG_XEN_PVHVM=y
CONFIG_XEN_MAX_DOMAIN_MEMORY=128
[code]...
View 3 Replies
View Related
Jan 25, 2009
I know how to search for normal files but can you let me know " How to search for 5 setuid files on the system. Also explain, for each file, why setuid mechanism is necessary for the command to function properly"
View 1 Replies
View Related
Aug 3, 2010
am new to linux and trying to find a file in sub directories using find command as:find .-name *.jpg -type fBut I am unable to get the result as find command is not permitted by the server administrator.Is there any way to find files without using find command.
View 14 Replies
View Related
Jul 1, 2010
I am trying to install some software to view/manipulate N-body simulations, Tipsy, and am getting this error: /usr/bin/ld: cannot find -lXext collect2: ld returned 1 exit status
View 2 Replies
View Related
Sep 22, 2010
I've observed a problem which stops me from mounting my external hard disk into my machine. I used a bash script to perform the mounting operation; but the script faced error, Whereas the mount command works properly correct when I use it directly in command line.
#!/bin/bash
mount_point= fdisk -l | sed -n '$p' | cut -c1-9
mount $mount_point /mnt
the code should have split the mount location of external hard disk in /etc/fstab and pass the mount_point' variable to mount command, but it doesn't.
ERROR:can't find /mnt in /etc/fstab or /etc/mtab
View 4 Replies
View Related
May 11, 2011
I've been around the block with this problem and don't know what else to check to compile source for gpsbabel-1.4.2. Other posts on this forum mentioning the same error with no resolution on this specifically. I have looked at the following:
1. The Makefile looks like this for the part compiling with expat options:
Code:
gpsbabel$(EXEEXT): configure Makefile $(OBJS)
$(CC) $(CFLAGS) $(LDFLAGS) $(OBJS) -lm -L/lib -lexpat -L/usr/lib -lusb $(OUTPUT_SWITCH)$@
2.Search for library files:
Code:
$find /usr/lib -type f -name "*expat*" -print
/lib/libexpat.so.1.5.2
/lib/libexpatw.so.1.5.2
[code]....
View 1 Replies
View Related
Jul 3, 2010
When i install libdrm, i get the following error:checking for clock_gettime... no.checking for clock_gettime in -lrt... no.configure: error: Couldn't find clock_gettime
It seems that it cannt find clock_gettime function, but i find it as follow:
$ grep clock_gettime /usr/include/time.h
extern int clock_gettime (clockid_t __clock_id, struct timespec *__tp) __THROW;
View 6 Replies
View Related
Mar 19, 2011
I don't want to go into a lot of detail as to why, but suffice to say, I detest autocomplete, anywhere, in any form. I'll leave it at that and save the venting for another time. Now, I've disabled autocomplete within a document, that's not too hard, by disabling the "Enable word completion." But, that seems to have no effect on the "Find & Replace" box. Googling doesn't seem to find anything, except another person that also seems to hate it on the OpenOffice message boards, and they were not helpful. That was also about five years ago, if that makes any difference.
View 2 Replies
View Related
Oct 12, 2010
I recently installed ubuntu on an external hdd. i tried turning on my laptop w/o the hdd connected and when it went to boot it gave me an error saying that it couldnt find grub. all i wanted to do was boot into windows 7. is there anyway to set it up so i can just boot off my main hdd for windows and use the bios and choose to boot off my external to boot grub and choose what i want to boot like say linux?
View 3 Replies
View Related
Sep 16, 2010
I am trying to run i386 in gcc_test-suite using dejagnu runtest and it fails with error given below. I can see that gcc-dg.exp is in folder gcc-4.6-20100911/gcc/testsuite/lib, but runtest is not searching in this folder.
how to resolve this issue and run only i386 tests.
$ cd /gcc-4.6-20100911/gcc/testsuite/gcc.target
$ runtest -a -tool i386 -verbose
....
....
Looking for library file /usr/local/share/dejagnu/lib/gcc-dg.exp
[Code].....
View 6 Replies
View Related
May 27, 2011
find /var/spool/mqueue -group abc -exec rm -rf {} ;Using above command , I delete all the files belong to group abc.Now the problem i face is that the this command gives error that some files are missing . And this error occur because after creating list of files, it pass that list to rm -rf but till that time sendmail process queue and some of files disapper from /var/spool/mqueue.
View 5 Replies
View Related
Apr 12, 2010
I am trying to install syslog-ng-3.0.2 on Fedora 12 and have run into an issue I don't know how to solve. When runing the "configure --enable-ssl" I get the following "checking for pkg-config... (cached) /usr/bin/pkg-config checking pkg-config is at least version 0.14 checking for GLIB - version >= 2.0... 2.0, bad version string no configure: error: Cannot find GLIB version >= 2.0: is pkg-config in path?" I have glib-2.24.0 installed on this system so I don't understand where this issue is coming from or how to fix it.
Back ground on my system -
[root@syslog-ng]# set PKG_CONFIG=/usr/lib/pkgconfig
[root@syslog-ng]# export PKG_CONFIG
View 8 Replies
View Related
Dec 25, 2009
I need to delete all *.trc files that are older than 30 days and I am getting a "Argument list too long" error. There are other files that should not be deleted which is why I am using the "*.trc" and newer files need to be kept as well. I have seen other postings but they do not cover both of the conditions. Below are 2 of the many attempts at doing this but I cannot get this to work.
find *.trc -mtime +31 -print| xargs rm -f {}
find *.trc -mtime +31 -print -exec rm -f {} ;
View 3 Replies
View Related
Dec 1, 2009
I had been trying to install Ubuntu 9.10 after formatting my machine. When i select install of the welcome screen, the logo blinks for few minutes and then displays a error as
Code:
Unable to find medium with live File System
Then goes to busy box.
"The same thing appears with Ubuntu 8.10, which i was using before!"
View 2 Replies
View Related
Jan 29, 2010
I am in the process of re-DL-ing the ISO as the checksums didn't match.
Mind you, that was with a shell extension in Win-Lose. Who knows.
Anyway:
I have the ISO (that I had previously) on a USB courtesy of UNetBootIn. All appears well until, quite quickly, I receive an error after the loading process which goes something like:
Code:
Error: cannot find disk at [hash-code - looks like 0ace5f etc etc, is about 12 char's in length.]Something very similar (but not same error I think) happened when I tried to do the same with my OpenSolaris or Fedora install. I.e., gets as far as the very beginning of the loader and then: bork.
At least one of them said "will reboot in 120 secs". Saves me the trouble!
View 2 Replies
View Related
Nov 11, 2010
We make everyday a DB Mysql backup on Linux redhat Enterprise. We are using a bash shell script (and putting it in the crontab) to execute it automatically everyday. We added a line to this script telling, once the backup has completed, to find old backup files (stored on hard disk after each backup) older than x days to remove them. We use the find command (search for file type) with the mtime option and in combination with rm command. Everything runs ok but we also want to add some new code to the same line: If find command cannot find anything or fails, for example if it cannot delete file or fails, send the error message (standard error output) to an error file (like error000001 and increasing) and mail the errorxxxx file to an email address for example to admin@companyname.com. What would be the code for this issue to add it to our find command in the same bash shell script??
View 2 Replies
View Related
Sep 9, 2010
i tried to install gcc-4.5.0 on opensuse 11.2 I gave ./configure but it gave the error couldn't find the c compiler.. the message was
[Code]....
View 2 Replies
View Related
Feb 14, 2011
I have builded a svn server using apache before. But recently I can not check out from the svn server,and error code is as follows:
svn: Can't find a temporary directory: Internal error
I have searched in the google,they said no space on the server.But my server have much space.
Filesystem Size Used Avail Use% Mounted on
/dev/sda1 49G 22G 24G 48% /
tmpfs 220M 0 220M 0% /dev/shm
/dev/sdb1 917G 867G 3.8G 100% /mnt/md0
/dev/hda1 151G 129G 15G 91% /mnt/meego
The server is at the /dev/hda1 partition.
View 7 Replies
View Related
Apr 12, 2011
how to rectify these errors..
RCC: Error in 'appchooser.qrc': Cannot find file 'accessories-dictionary.png'
RCC: Error in 'appchooser.qrc': Cannot find file 'akregator.png'
RCC: Error in 'appchooser.qrc': Cannot find file 'digikam.png'
RCC: Error in 'appchooser.qrc': Cannot find file 'k3b.png'
RCC: Warning: No resources in 'appchooser.qrc'.
and my .qrc file is like this
<!DOCTYPE RCC><RCC version="1.0">
<qresource>
<file>accessories-dictionary.png</file>
<file>akregator.png</file>
<file>digikam.png</file>
code....
View 3 Replies
View Related
Aug 9, 2011
The find command does not seem to find all files in my directory hierarchy. My home directory is automounted from a server. The command to illustrate this is:find | sed -e 's/^.///' | sed -e 's//.*//' | sort -uThe result misses several directories. Likewise, a find of a particular file, like:find . -iname *sample* -printwhere sample_file.txt resides in one of the directories that is missing in the first find command, finds nothing
View 4 Replies
View Related
Feb 6, 2010
when i was about to install turbo c using dosbox in ubuntu on the console i typed the commandas sudo apt-get install dosbox the error occured as E:couldnt find the package dosbox
View 5 Replies
View Related
Jan 30, 2011
I am finding the following error while compiling
collect2: ld returned 1 exit status
/usr/bin/ld: cannot find -lfl
View 2 Replies
View Related
Jan 20, 2011
I am try to compile and install the as31 program development for the 80c51, but I am getting an error during compiling cannot find "gtk/gtk.h" I downloaded it from /www.pjrc.com/tech/8051/.I send an email to "paul@pjrc.com", he toll me to install gtk1.2-dev indicating that, On Ubuntu, the command is: "apt-get install libgtk1.2-dev"it still produces the error. I am using an HP laptop zv6000 running Fedora 14 and appears that gtk2 and gtk3 is installed This is the result:
[Vinny@HP1 ~]$ apt-get install libgtk1.2-dev
bash: apt-get: command not found...
Install package 'apt' to provide command 'apt-get'? [N/y]
[code]....
View 2 Replies
View Related