i need a unix script that has to check the text file exists or not in all directories and sub directories if textfile exists display the directory path else display does not exists!!
example: kamal.txt that i want to search if the file exists are not in all the directories....
sh <scriptname.sh> <only-filename.txt> will be given by user while running....
first i am checking whether the textfile exists or not in all directories...
i have taken sample.txt file as example for input which exists in root directory..
this is the command that i have given: find / -path sample.txt -print
but output nothing was displayed
pls help me in solving this...