How do I browse CentOS packages?
Generically speacking
yum search "search-string"
will search any of your configured and enabled repo's, though its not always handy to use yum / rpm commands if your stuck on something like a .so.* dependency failure. EDIT: I know the above isn't web, but there are yum GUI's around that emulate that function, I just can never remember a good one so prefer the command line.
For dependencies and as a general goto for rpm searching I use: http://rpm.pbone.net/ click the advanced search link to narrow the search to your distros.
I find this an awesome resource as it doesn't just index the redhat/fedora/suse default repos, though I'm not sure if it includes RPMFusion (which is another great 3rd Party source and is searchable).
Related videos on Youtube
![devsda](https://i.stack.imgur.com/EPDFt.jpg?s=256&g=1)
devsda
Updated on September 17, 2022Comments
-
devsda almost 2 years
I want to make a log in the java code. And, the whole process takes hours to finish. But my code makes all the log at the end of the execution, because buffer is closed at the end.
Is there any method, so that I can append in the log file ?
Please see my code, and suggest some necessary changes. Thanks in advance.
My code,
public class test { public static void func(String url1, String url2, BufferedWriter bw) throws InterruptedException, IOException { long loading_time = 10878; long parsing_time = 120; long processing_time = 329; Thread.sleep(100000000); // Here is some process that performs recursively bw.write( url1 + "\n" + url2 + "\n"+ ((double)loading_time)/((double)1000)+ " seconds " + ((double)parsing_time)/((double)1000) + " seconds " + ((double)processing_time)/((double)1000) + " seconds\n\n\n\n" ); } public static void main(String[] args) throws IOException, InterruptedException{ try { FileWriter fw = new FileWriter("C:\\Users\\jhamb\\Desktop\\log.txt"); BufferedWriter bw = new BufferedWriter(fw); for(int i = 0; i < 5; i++) { func("hitesh", "jhamb", bw); } bw.close(); } catch (Exception e) { System.out.println("Sorry some problem"); } } }
-
rajesh about 11 yearsuse any logging framework
-
devsda about 11 years@rajesh Please see my above code, and please suggest me how can I change this ?
-
-
rajesh about 11 yearsBut you have to use a framework to log rather than writing yourself. This will be one think that you will use in all your code.
-
rajesh about 11 yearsFile path will be based on your log config.
-
devsda about 11 yearsI seriously don't know anything about this, please tell me where the log config is ?
-
gkdsp almost 11 yearsFYI: The following warns against using Fedora RPMs as substitute for CentOS... serverfault.com/questions/71299/…