apt get life

Life around technology

  • Technology
    • Guides
    • Linux
    • Development
      • Laravel
    • Misc
    • Raspberry Pi
  • Writing
  • Crafts
    • Crochet
    • Model Making
    • Painting
  • Privacy Policy
You are here: Home / Archives for sudo

Setting up a Buildroot Environment on Ubuntu or Mint

2015/07/16 by sudo

I’ve got a project that requires really fast boot times, so I’ve been looking into buildroot, which is a tool for building embedded Linux systems. When I started playing with the tutotials I noticed that I was getting errors with the make menuconfig command:

make menuconfig

...

/development/rpi_buildroot/buildroot/output/build/buildroot-config/conf.o
 *** Unable to find the ncurses libraries or the
 *** required header files.
 *** 'make menuconfig' requires the ncurses libraries.
 *** 
 *** Install ncurses (ncurses-devel) and try again.
 *** 

In order to use buildroot on Ubuntu or Linux Mint the following packages need to be installed:

sudo apt-get install build-essential ncurses-base ncurses-bin libncurses5-dev dialog

After which you should be able to run make menuconfig without errors.

 

Filed Under: Linux, Technology

Fixing Raspberry Pi Arch ‘pacman-db-upgrade’ Permissions Error

2015/07/14 by sudo

I’ve installed Arch Linux on the Raspberry Pi for the first time, and after getting the package manager pacman to update all of the software to the latest versions I’ve been getting the following error:

error: try running pacman-db-upgrade

When running the upgrade command this permissions error was returned:

ERROR: You must have correct permissions to upgrade the database.

After looking at several forum posts I discovered that the upgrade made my filesystem read-only. To fix this edit /boot/cmdline.txt and add the rw flag

nano /boot/cmdline.txt

selinux=0 plymouth.enable=0 smsc95xx.turbo_mode=N dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA0,115200 console=tty1 root=/dev/mmcblk0p6 rootfstype=ext4 elevator=noop rw rootwait

Your installation my have a different cmdline.txt file, but the important bit is the rw flag, usually placed after the root filesystem is declared.

For more information see this forum post: https://www.raspberrypi.org/forums/viewtopic.php?f=53&t=97657

 

Filed Under: Raspberry Pi, Technology Tagged With: arch, pacman, raspberry pi

Solving Error: Piwik is already installed

2015/06/27 by sudo

Recently, I’ve been migrating sites to a new server. This included my Piwik installation for website statistics. In order to move Piwik I used mysqldump to backup the database, copied the sites files and restored them to a new server. When accessing Piwik for the first time after the migration I was greeted by the error:

Error: Piwik is already installed

Now, I know this is the only instance on my brand new server, and I know I restored the database correctly. I did some googling to find this is a common problem for migrating Piwik to a new server, but solutions proved to be lacking. In the end I moved the config.ini.php that contains the database connection to a backup location:

mv config/config.ini.php config/config.ini.php.old

I then re-ran the Piwik installation with the same details as I had in the original config file. This wiped my data, but after setup was finished I restored my backup from the original server again:

mysql -u root -p piwik < piwik.sql

Once I logged in all of my old data was available and Piwik was working again!

 

You may be interested in the following forum posts on the Piwik site:

  • http://forum.piwik.org/read.php?2,124781 – Piwik error already installed forum post with no solution
  • http://forum.piwik.org/read.php?2,123744 – Piwik error already installed forum post with no solution

Filed Under: Guides, Technology Tagged With: piwik, web analytics

Solving Debian 8 Jessie resolv.conf update issues

2015/06/18 by sudo

With Debian Jessie, resolv.conf, which stores the name servers for the computer to use when looking up DNS requests, seems to automatically reset every so often. This results in the DNS lookup time for each request sent through the proxy to take longer if the name servers listed are not accurate or fast. For example, my resolv.conf file contained the following by default:

nameserver 192.168.0.1

The IP address listed is that of the router, which for some reason was taking an age to actually respond to requests. Originally I tried to edit this file by hand but it kept clearing itself back to default. This seems to be a particular issue in Debian Jessie.

To resolve the problem, I installed resolvconf, which is a program which has been designed to update the systems information about name servers.

apt-get install resolvconf

Once installed it’s easy enough to add the new name servers to the configuration file. I chose Google’s as a test, since they’re likely to be fast.

nano /etc/resolvconf/resolv.conf.d/head

In the file I added the two IP v4 name servers for google so that it looked like this:

# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
#     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN
nameserver 8.8.8.8
nameserver 8.8.4.4

Now that is in there, and of course you can change the name servers as you see fit, it’s just a case of running the update to resolvconf

resolvconf -u

Now your /etc/resolv.conf file should have your two lines prepended to it. Since the file works in top down priority your new requests will be sent to 8.8.8.8 by default. After implementing this Squid increased in speed significantly.

 

You may also be interested in reading alternative solutions on this particular thread at unix.stackexchagne.com.

 

 

Filed Under: Guides, Linux Tagged With: debian, debian jessie, nameservers, resolv.conf

Social Media Buttons

2015/03/15 by sudo

Ignoring the potential privacy issues associated with social media buttons, they can be a useful asset to content creators and consumers. A social media “share” button allows you to easily share content on a social media site, and statistics (which tend to be from the social networks) show that it can dramatically increase your visibility online.

The following are direct links to the social media websites’ individual generator scripts:

    • Linked in
    • Facebook
    • Twitter
    • Google+

For more information, this page lists a range of social media networks and share button types: http://blog.hubspot.com/blog/tabid/6307/bid/29544/The-Ultimate-Cheat-Sheet-for-Creating-Social-Media-Buttons.aspx

Filed Under: Misc

  • « Previous Page
  • 1
  • …
  • 8
  • 9
  • 10
  • 11
  • 12
  • …
  • 15
  • Next Page »

Recent Posts

  • System Hang on Ubuntu 24.04 “e1000_print_hw_hang”
  • Disable iLO on HP Microserver Gen8
  • Ubuntu Desktop 24.04 Change Wallpaper Settings
  • Customising Ubuntu Desktop 24.04
  • Remove domains from Let’s Encrypt using Certbot

Tags

API auditing crochet data recovery debian debudding development Dingo API docker email Getting started with Laravel 5 & Dingo API hard drive health HP Microserver KVM Laravel larvel 5 lenovo Linux Minion mint netgear nas networking network shares php PHP development Postfix raspberry pi review samba security SMART smartctl smartmontools smb testing traefik ubuntu ubuntu 18.04 ubuntu 20.04 ubuntu 22.04 ubuntu server vagrant Virtual machines xdebug xubuntu

© Copyright 2015 apt get life