Hi I want to find count of file between 2 size (for example 1k and 2k) in linux, I found that the code return the count of exact size in a directory and it work fine: could anyone help me how I do find between 2 size? And is it possible that I find the count of Hiden file via
Tag: linux
How to create a system-wide file lock?
I am trying to have a number of independent processes coordinate their writing to file using a system-wide lock (see here: Concurrent file accesses from different scripts python) The lock needs to span the whole system, because the processes are spawn independently and at different times. Here: System-wide mu…
Cron format for specific date and time, running once a year only
I have to schedule the cron to run at specified time. I have the command like below. But I could not understand how to run only once in a year at a specified date and time. My question is: what should the value for 5th field (Day of the Week) be? Time/date: Jan 2nd 06:30 AM – only once in
extracting a n element from a list with dolist on lisp
I am trying to create a function where it takes a list of letters as parameter and a single letter as a parameter. I want to remove the single letter from the list. so if I call the function with (extract-all ‘n ‘(i n t e l l)), I want it to return i t e l l with the
How to clear CPU cached owned by a process in Linux x86
I want to get the kernel APIs which can be used to flush/clear the CPU cache owned by a specific process. Answer There’s no such thing as “CPU cache owned by a process”. The CPU / memory controller manages the cache, not the OS. On some CPU architectures (I don’t know!) it might be pos…
Connect to Vehicle Using Telemetry on Linux
I am having problems with connection to vehicle. First, I could not connect to the vehicle even with USB (I used “/dev/ttyUSB0” connection string and got an error). Later I got it working with connection string ‘/dev/serial/by-id/usb-3D_Robotics_PX4_FMU_v2.x_0-if00’ and was able to sen…
How to delete lines that match elements from another file
I am in the process of learning Perl and I am trying to figure out how to do this task. I have a folder with a bunch of text files and I have a file ions_solvents_cofactors that contains bunch of three letters list. I wrote a script that opens and reads each file in a folder and should delete those
Change some field separators in awk
I have a input file 1.txt and I want an output file: out.txt I want to replace the first two ‘:’ in 1.txt with ‘||o||’, but with the script I am using But it is not giving the expected output. Any help would be highly appreciated. Answer Following sed may also help you in same. Explana…
how to disassebled binary with source line and file name using gcc-linaro-arm-linux-gnueabihf-objdump?
I want to get the disassebled binary files with source line and file name. I have added option -g as a compilation option,following is the setting in cmake files. And following is my objdump bash script: From the instructions, I should have a asm file with source line and file name just as https://manpages.de…
Using sysctl interface from kernel module
I am trying to access tcp_pacing_ss_ratio defined in tcp_input.c from a kernel module. The variable can be modified using the sysctl command in user space. It is however not exported and cannot be referenced directly from the module. What is the simplest way to access a sysctl entry from a kernel module? Answ…