Skip to content
Advertisement

Tag: ubuntu

how to customize select loop in bash

I was wondering if is possible customize the select loop for bash. I have this code: Output is something like this: I would like to order the options in landscape view and also change the prompt [#?] by something else Thanks Answer select displays the PS3 prompt. You could try something like:

how to use git log and grep together?

I am trying to use git log and grep together with pipe. However, it doesn’t seem to work. I am grepping for the bug-id from the git log. Here is what I am doing. Answer You can use git log –grep “BUG-1024”

Ubuntu kernel kills CPLEX ILP process due to out of memory

I’m working with the ILOG CPLEX library in Java to solve an ILP problem. I’m using the default settings and did not adjust any parameters. I used the example code which I found online in samples for my main loop: I launched my jar on an Ubuntu 14 system with 24GB RAM and let it solve larger problems. When my

Cannot pass STDIN using shell_exec() in PHP

I am a complete beginner in PHP. I want to execute a java .jar file using PHP.The jar file takes input from STDIN and generates the output at STDOUT.To execute the jar file this is what I do in my Ubuntu Linux terminal: This works perfect.However when I replicate this in PHP as: This sends $p the output generated when

Docker container apt-get install can’t find package

I’m trying to spin up a docker container that populates mongo via a node.js script that I have. With the script below, I get the error : with this dockerfile: Why does apt-get not find nodejs? Answer Seems i was missing RUN curl –silent –location https://deb.nodesource.com/setup_0.10 | bash – before the apt-get install

‘exec(): Unable to fork’ on Ubuntu 14.04.3 LTS

I’m running unittest scripts and for test case setup I need to run shell command from time to time. As a result shell command is run around 50 times during unittest execution. It works ok on CentOS release 6.6 (Final) server but doesn’t work on Ubuntu 14.04.3 LTS. The problem is that after around 20th time shell script execution I

Create user on remote linux with Jenkins

I need to run a ssh script on a remote linux server to add a user but nothing I do quite works. I make up the username of 2 Parameters and then try to make the password of which the first part is a set string but the second part is also a Parameter. I am using the Jenkins SSH

Command to change tomcat server port

I’m using ubuntu, and I’m in a need of some command, using which I can change the server port configurations. Therefore, my question is… Is there any linux command, to update the Tomcat server connection port, as well as server shutdown port? Answer maksim_khokhlov answer looks promising if you want to change it at the start (it is taken from

perf enable demangling of callgraph

How do I enable C++ demangling for the perf callgraph? It seems to demangle symbols when I go into annotate mode, but not in the main callgraph. Sample code (using Google Benchmark): build command: perf commands: I’ve also tried enabling the –demangle option, but that doesn’t seem to affect the output. callgraph missing demangled symbols: annotated disassembly showing demangled calls:

DataStax opscenterd won’t start on Ubuntu 15.04 x64

Issue: sudo service opscenterd start Failed to start opscenterd.service: Unit opscenterd.service failed to load: No such file or directory. (ERROR)-(Exit Code 6)-(Unknown error code) sudo service opscenterd status opscenterd.service Loaded: not-found (Reason: No such file or directory) Active: inactive (dead) Config [webserver] port = 8888 interface = 0.0.0.0 I tried another port and ip (localhost) Cassandra installed and running (dsc21,

Advertisement