Questions tagged [linux]

Linux is a popular, open source operating system kernel. Linus Torvalds started development of the kernel in 1991.

Filter by
Sorted by
Tagged with
2 votes
1 answer
48 views

Linux poll with a thread pool and multiple events

I am working on a simple client server program in C in which multiple clients will be connected to a single server. Clients will submit operations/actions to the server and the server will process ...
nick2225's user avatar
  • 149
1 vote
0 answers
55 views

KRaft design architecture - Separation of Controllers and Brokers

We want to install Kafka Kraft cluster on 35 machines ( machines are DELL physical machines - type R760 And OS is Linux RHEL 8.6 version ) Since we are dealing with Kafka production cluster , we want ...
jessica's user avatar
  • 111
0 votes
1 answer
177 views

Is it secured to accept and execute user provided CURL commands

Assume you have to figure out a dynamic way where the user can provide an API call to hit in the backend for example, user to provide a webhook to call on his end server So, An idea for users to ...
Youans's user avatar
  • 441
-1 votes
1 answer
191 views

What does "de-MFC'ifying"a GUI app consist of? [closed]

I'm planning to port or rewrite an MFC GUI C++ app, to use in a GNU/Linux environment, and hopefully make it cross-platform. The app has few, if any, dependencies other than MFC and the standard C++ ...
einpoklum's user avatar
  • 2,488
1 vote
2 answers
462 views

Why does linux require that newly added syscalls be supported permanently?

I was reading some of the documentation for the linux kernel and I stumbled upon an article about adding new syscalls to the linux kernel. The article essentially says that any syscall in the linux ...
Danila Berezin's user avatar
0 votes
1 answer
43 views

How to check for docker specific code and APIs in an application for later migration to containerd?

So I have a couple of Java RESTful microservices, and since the past few years I have basically been using Docker to build them and deploy them over to a Kubernetes cluster. Our team is upgrading ...
dnak's user avatar
  • 3
0 votes
2 answers
261 views

On hanging Desktop-applications

I am filled with questions pertaining to the situations where a desktop-application hangs, possibly for minutes. I've got this complicated game-engine written in c++. Several times during development, ...
SilverRain's user avatar
0 votes
1 answer
171 views

Help architect a timer-based scheduler

I am writing a timer-based scheduler to accomplish the task of informing a certain process of what to do and when. The Idea: Inform an X process of certain requests to perform at timed-intervals. So ...
xyf's user avatar
  • 109
0 votes
2 answers
236 views

What makes a program load so fast?

What makes programs like st, zathura, sxiv, and feh load instantly and what makes programs like VS Code and Google Chrome load so slowly in low-spec computers? For example, I have a low-spec laptop ...
Wade Wayne's user avatar
-5 votes
2 answers
89 views

Feasibility of adding drivers to linux kernel

I have question regarding Linux kernel , as far as I understand, to make Linux compatible with different machines and hardware , different device driver is added to the Linux . I want to ask how much ...
user143252's user avatar
0 votes
1 answer
715 views

Secure IPC method for C++ in Linux

I just can't choose a method of interprocess communication that would fit my goals, so I ask for help. My list of needs is as follows: It must be safe. Communication should not be hacked. ...
Dines's user avatar
  • 21
-1 votes
3 answers
391 views

Is it possible to solve this synchronization problem using mutex and conditional variables?

I am trying to solve this synchronization problem in C to practice for my lectures of Operating Systems where we use POSIX and Linux. I've been trying for days to find an approach to this problem with ...
78dtat78da's user avatar
2 votes
2 answers
210 views

Can the operating system "break up" a memory allocation (Linux)?

Let's say a process (P1) is asking for 100 MB of memory, and the RAM looks like this: [[50 MB free] [USED] [60 MB free] [USED]] Since there are technically enough memory that are available (110MB ...
qwerty_99's user avatar
  • 163
-1 votes
1 answer
450 views

Local Path on Linux [closed]

As we all know /usr/local/sbin, /usr/local/bin, /usr/bin, /sbin, /bin, /usr/games, /usr/local/games and /snap/bin are directories that Linux commands ( Except ones that built-in to shell and custom ...
maDeveloper's user avatar
-3 votes
1 answer
183 views

Is there any reason I shouldn't use a LInux host for a Linux guest VM?

I'm a developer and my typical environment is to use is a Linux guest OS running inside VirtualBox on a Windows host. Most software companies don't allow developers to install Linux bare metal on ...
Johnny Alpha's user avatar
0 votes
1 answer
277 views

How to efficiently communicate with Raspberry Pi using Django/Python

I have a raspberry pi that is sending an https request to my Django application every 2 seconds. The request is essentially asking the application 'Has a user requested data from me?' My Django ...
MattG's user avatar
  • 103
0 votes
1 answer
865 views

Is there a way to use git with multiple users on a shared computer?

I'm currently a user of a large research compute cluster which has many other users. We all have access to a shared program that is being actively developed and used. Since we are all effectively ...
Charlie's user avatar
  • 37
1 vote
2 answers
86 views

What does the inode point to in case of a device file other than the disk?

I know that the inode points to the actual disk blocks in the case of the normal file system. But what does it point to in the case of .... say .... the terminal device file. Does it point to the ...
ShayakSarkar's user avatar
-2 votes
3 answers
169 views

If you're building an algorithm from the C stdlib in pure Assembly (with no help), what is the best workflow for debugging/iterating?

I am a JavaScript developer mainly, so I am familiar with object-oriented code and dealing with things you can see easily and interact with, like the GUI, even HTTP requests, etc. Plus you can put ...
Lance's user avatar
  • 2,561
0 votes
1 answer
68 views

PHP: What code should be removed to its own helper class and where should such classes be located in the filesystem?

The following is an example requesting an explanation for one specific file in one specific filesystem, not helper classes generally. I have configured a LEPP stack on a CentOS server. The server ...
Muckee's user avatar
  • 111
-4 votes
3 answers
963 views

How to Write Pure Machine Code for Linux?

I'm writing a compiler, and I want it to compile to a native executable (just Linux, for now). I don't want it to be Assembly, it needs to be PURE machine code. Can anyone point me in the right ...
InfiniteDonuts's user avatar
1 vote
1 answer
130 views

Is it common to include a specific build of a library/ tool for production level project?

I am working with C++ in a Linux/ Unix environment. I am trying to learn the physical design of large scale projects. In one of my projects, I am using an SDK from a camera manufacturer. They released ...
skr's user avatar
  • 123
0 votes
1 answer
285 views

C++ Project Structure in UNIX/Linux environment: test and app folder

I am trying to figure out the right project structure for C++ and I am working on Ubuntu using CMake. I mostly work on AI/ Robotics/ Data Science. Assume that I want to generate executables and ...
skr's user avatar
  • 123
-2 votes
1 answer
882 views

In C++ and GCC on Linux, is it possible to allocate memory to your swap space instead of your RAM?

I have a large hash, around 6 gigabytes that I load into memory. On my current laptop that I develop from, it really does a number on my system, causing massive amounts of lag while I try to go about ...
Anon's user avatar
  • 3,575
-4 votes
1 answer
155 views

How to Create an Application on Linux? [closed]

I want to create a program for the Linux OS in Haskell with multiple .hs files. I don't need help with the code or compiling it, what I don't know how to do is create an application that can be called ...
InfiniteDonuts's user avatar
-1 votes
2 answers
127 views

Detecting keyboard "callbacks" directly from a keyboard not from a operating system

So, I am making a pure 2D shooter in Unity, and I was thinking about cheats a little bit (Yes, I know that nobody is going to play my game but anyway). I was wondering if you can get pressed keys ...
Peter Veris's user avatar
1 vote
1 answer
80 views

Propper way to organize and maintain project SDK

There is a C++ project. It is supposed to be executed on x86 CPU, target OS are Ubuntu 18.04 and Red Hat 7.4. There is an idea that there is almost no need to install anything project specific on a ...
NwMan's user avatar
  • 21
0 votes
0 answers
318 views

C++ client-server design

The context I need to design a Client-Server(-Client) network in C++ that would allow an android application to communicate to a Raspberry Pi and back I am running everything on linux environment(s) ...
bem22's user avatar
  • 109
1 vote
1 answer
317 views

Build docker images for GUI applications in Linux

Currently I'm building GUI applications for Linux and they have many dependencies( We ship Raspberry Pi devices with the executable installed on each device). My idea is to create a docker image for ...
pruthvidr's user avatar
1 vote
1 answer
96 views

Simple question about terminal memory [closed]

I'm running a program in C++ on a Chromebook Penguin terminal. The program runs perfectly the first time, but on consecutive runs it acquires different results. I suspect that this is because the ...
Jerod Horsch's user avatar
6 votes
3 answers
995 views

practical copy/paste clipboard model of recent web HTML5 browsers?

the reader is expected to be an advanced Linux developer, having read ALP and having developed advanced GUI applications on Linux using GTK or Qt; notice that sadly I am not a native English speaker (...
Basile Starynkevitch's user avatar
2 votes
1 answer
1k views

How can I sync a git repository with directories from another machine?

My team and I use a git repository to keep track of our projects. This repository is cloned in our Windows PCs that we use to develop most of our software. However, we also use another machine ( a ...
AirBlast's user avatar
2 votes
1 answer
540 views

Is there such a thing as linking to too many dynamic libraries in Linux?

I'm currently considering breaking down one of my libraries in some 20 Debian sub-projects. Each part is already pretty much a standalone bit in the existing large library. What I'm wondering is the ...
Alexis Wilke's user avatar
1 vote
0 answers
60 views

How to design a highly available and fault tolerant file storage drop location in linux box

Am trying to build a highly available and fault tolerant file drop location in linux server. Please find the current system design below: We got 2 linux servers in secured zone into which several ...
Valath's user avatar
  • 127
0 votes
1 answer
272 views

REST-like HTTP POST request with JSON

I am coding a poof-of-concept throw-away GCC plugin (see this for more context) which would use the HTTP 1.1 protocol to interact with my Bismon (GPLv3+ code on github, but unreleased; draft technical ...
Basile Starynkevitch's user avatar
0 votes
1 answer
26 views

Set per-process open file limit in code or in system configuration?

I am working on an internal application that is maintained by the same people that operate the servers the application runs on. We have noticed, while transitioning from Windows to Linux, that some ...
kqr's user avatar
  • 369
10 votes
3 answers
32k views

JSON without quotes for keys

I need a textual human readable format which is reasonably compact and version-control friendly to serialize a persistent memory heap. My Bismon system (GPLv3) has such a format (it is textual, human-...
Basile Starynkevitch's user avatar
2 votes
1 answer
61 views

Architecture design for Linux administrative interface

I've developed an IoT device utilising OpenWrt so my design needs run a on a shoe-string budget of resources. I need to be able to push small amounts of data, up to 300bytes to my app on a very ...
user1232212's user avatar
2 votes
1 answer
128 views

Can we use the term "driver" for a software layer that doesn't access a physical device? [closed]

Say we have the following image (which is about Linux): Can we call the file systems boxes that are shown in the image (ext2, msdos, and minix) "file systems drivers", for example can we say that the ...
user4582812's user avatar
-3 votes
3 answers
697 views

Ken thompson's compiler hack [duplicate]

I have gone through ken thompson's compiler hack paper, can't we just go through the complier's source code and check for any backdoor, what was the article's point? https://www.archive.ece.cmu.edu/~...
user9355495's user avatar
4 votes
3 answers
5k views

can two web browser tabs be distinguished in a single-page application?

motivation and context I am designing and implementing the web interface of my bismon server program (a research prototype; in a few words: an orthogonally persistent, reflexive, homoiconic, ...
Basile Starynkevitch's user avatar
7 votes
2 answers
8k views

Is it good practice to statically link libstdc++ and/or libgcc when creating distributable binaries for Linux?

Context: I have an open source project which uses JNI. While it's possible to build it yourself, I expect most users will use standard Java tools like Maven, Gradle, or SBT to download the JAR, which ...
Robert Fraser's user avatar
0 votes
3 answers
304 views

How to append a chunk of fixed size data to a file and make sure this chunk doesn't get fragmented on disk?

So i want to understand how DBMS implementation works To give an example : MySQL implements each tables with its own pages, which are 16KB so each table is a file, and is a multiple of 16KB, ...
OneAndOnly's user avatar
2 votes
1 answer
425 views

Why do we need nginx server on top of linux server?

Recently, I tried to deploy a web project to a virtual machine. I used the Ubuntu server as my OS, but while following along some tutorials I came to the fact which was very confusing for the beginner ...
Aziz's user avatar
  • 123
0 votes
2 answers
101 views

Create clean/blank MacOS filesystem for testing OSS

In developing/testing OSS libraries I can replicate a clean Linux fs using containers. However, if I want to test oss libs for MacOS end users, I seem to be in a bit of a quandary. Is there any way to ...
Alexander Mills's user avatar
1 vote
1 answer
258 views

Should worker processes accept() or should they get data from the master process?

I'm trying to write an application server in python. I have a master process and multiple worker processes created from the master using fork(). I have two approaches in mind about how the workers ...
akshay takkar's user avatar
1 vote
0 answers
435 views

Daemon vs worker and when to use what?

(Note that, below, I am frequently using term "daemon or worker" just to indicate that I dont know which word to use as I dont know the exact difference between them in the context explained below.) ...
Mahesha999's user avatar
1 vote
3 answers
866 views

Is an OS kernel a singleton?

In my understanding, a singleton design pattern is where we have only one instance of an object in a system. I am not sure on this part of the definition, but I believe in an OS there is only one ...
Decimak's user avatar
  • 69
3 votes
4 answers
2k views

What is the technical term for the modifiers that come after a command?

For instance: python3 -m What is the technical term for the "-m" ? And, where can I find a list of these "modifiers" that correspond to a command? Then, how would I find out what each of these "-...
BBD's user avatar
  • 49
2 votes
1 answer
75 views

How can I maintain bash functions without brittle escaped newlines?

I have functions like this: foo() { /some/script \ --opt1=val1 \ --opt2=val2 \ --opt3=val3 } This is brittle if I take out the last option, or add any new option at any line. ...
djechlin's user avatar
  • 2,212

1
2 3 4 5 6