Skip to content

Tag: ubuntu

replace text between two tabs – sed

I have the following input files: and I am trying to find the second string between the two tabs (e.g. text2, abc2) and replace it with another word. I have tried with but it only deletes the tab and does not replace the word. I appreciate any help! Answer I would suggest using awk here: Set the input and out…

Php.ini changes are not taken on Linux Bitnami Ubuntu

I am using a LAMP stack from Bitnami with Ubuntu. I am trying to increase post_max_size in file php.ini. I changed these values: Then reset with sudo /opt/bitnami/ctlscript.sh restart php-fpm (taken from the Bitnami documentation). No changes take effect. I have tried removing all the text from php.ini. I get…

PHP fopen ‘x+’ doesn’t work on ubuntu

I created an application which has an caching script on an Windows/Wamp environment. This script’s caching function is only allowed to run once at the same time. To achieve this I used a ‘locking file’ with check to see if it exists. On windows this script continues to work fine. But now it …

How to move window offscreen with wmctrl

I am trying to programmatically move a window so that it is partially on screen. For instance, clicking the VLC title bar and dragging it so that only half the window is visible works just fine. When I output the results of wmctrl -lG this works just fine: However, when I then move it back on screen and try a…

Error: mime-types-data requires Ruby version >= 2.0

I recently install clean ubuntu14.04 virtual machine in vware fusion and updated it. I am trying to install the mime-tyes-data by sudo gem install mime-types-data -v 3.2015.1120 The error shows ERROR: Error installing mime-types-data: mime-types-data requires Ruby version >= 2.0. Before that I already upda…

Pointers and virtual memory [closed]

Closed. This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed 6 years ago. Improve this question According to my system’s cpuinfo file, each processor in my system has a 39 bit physic…