Category "linux"

How to get CPU clock frequency on an ARM/Linux machine

The answer seems pretty obvious I guess but none of the possible answers given in https://superuser.com/questions/406141/how-to-get-an-arm-cpu-clock-speed-in-li

Why can the posix thread id be NULL in Linux kernel function filp_close?

Below is excerpted from linux kernel: /* * "id" is the POSIX thread ID. We use the * files pointer for this.. */ int filp_close(struct file *filp, fl_owner_

Upgrade PHP on AWS Linux

I have an AWS server running a website with NGINX and PHP. I originally installed these using the following: sudo yum install -y nginx php-fpm The version of

Docker container accessible only via Cloudflare CDN (selected ip ranges)

I have webserver in docker container, but I cannot configure iptables on my host (Debian). I want allow only specified ip addressess to connect on ports 80 and

check library version netcdf linux

how do I determine which version of the netcdf library is installed in my system? Is there a command line? I tried to search "netcdf" and I find a bunch of file

Using sed to replace tab with spaces

I'm trying to replace the tab with 4 spaces, using sed, but it is not working. Here is my code: sed -i '{s/\t/ \{4\}/g}' filename Any suggestion is apprecia

Determine architecture when compiling linux module

I am writing a kernel module and in it I have the following piece of code: dma_dev->coherent_dma_mask = DMA_BIT_MASK(64); I do not always want 64 in there

MongoError: connect ECONNREFUSED 127.0.0.1:27017

I'm using NodeJS wih MongoDB using mongodb package. When I run mongod command it works fine and gives "waiting for connection on port 27017". So, mongod seems t

Bluetooth pairing in C blueZ on Linux

I cannot find any reference on how to pair a bluetooth device on linux in a program written in C using the BlueZ Bluetooth libraries. I already managed to do a

OCS Inventory integration in iTop Combodo

i have a big problem with the integrations in iTop by Combodo, I hope anybody can help me :) To my Problem... I have two servers with Linux Ubuntu 18.04LTS, one

Decoding output from Valgrind

I'm trying to understand the output from Valgrind having executed it as follows: valgrind --leak-check=yes "someprogram" The output is here: ==30347== ==30347=

How can I setup network traffic alerts on a Linux machine using Prometheus?

I am using Prometheus to monitor network traffic on Linux machines. I see several useful metrics like node_network_receive_bytes_total, node_network_transmit_by

Not able to create flutter linux desktop application snapcraft build

I have developed a Linux desktop application with the help of flutter but now I am facing an error when I am trying to create the snapcraft build in #Flutter Pr

How Do I Clear The Credentials In AWS Configure?

I have deleted the AWS credentials in sudo nano ~/.aws/config. But, the credentials are still in aws configure. Is there a way to reset aws configure with clear

simple_read_from_buffer/simple_write_to_buffer vs. copy_to_user/copy_from_user

I recently wrote a module implementing these functions. What is the difference between the two? From my understanding, the copy_..._user functions are more sec

How to remove setgid (linux/unix)?

I just changed my file permissions using $ sudo chmod g+s filename and my file permissions turned from drwxr-xr-x to drwxr-sr-x. How do I remove it?

gensim error : no module named gensim

I trying to import gensim. I have the following code import gensim model = gensim.models.Word2Vec.load_word2vec_format('./model/GoogleNews- vectors-negative

how to compare only date from a model's datetimefield with current date?

I want to use Model.objects.filter(datetime_lte=datetime.datetime.now.date()) How exactly can I achieve this? I am using django 1.6.5. I want only records of cu

WebDriverException: no chrome binary at /usr/bin/google-chrome-stable or chrome binary not found

I am executing selenium test via Jenkins server in AWS Ubuntu. I was getting chrome binary not found error so I set chrome binary in my code. System.setPrope

How to measure the stack size of a process?

How do I find the stack size of a process ? /proc/5848/status gives me VmStk but this doesnt change No matter how much ever while loop and recursion I do in m