Well, about ten minutes after installing the new Owncloud Nine we found out that we had typo’d the admin password. Fortunately, it’s an easy fix. Run the following (this worked on Debian with a fresh Owncloud 9 install):
sudo -u webserveruser php occ user:resetpassword adminaccountname
In our case the command was:
sudo -u www-data php occ user:resetpassword admin
It should prompt you for your password twice:
Assuming there are no more typos, that’s all done!
If you have a lot of virtual (or real) machines running Debian or Ubuntu and a limited internet connection, it can make a lot of sense to use apt-cacher-ng to create a local cache of the packages you use so that they are only downloaded once. The current version of apt-cacher-ng can also help out with yum repositories!
On CentOS, edit /etc/yum.conf and add:
If you have changed the default port of apt-cacher-ng from 3142, you will need to modify that. Our example file:
# This is the default, if you make this bigger yum won’t see if the metadata
# is newer on the remote and so you’ll “gain” the bandwidth of not having to
# download the new metadata and “pay” for it by yum not having correct
# It is esp. important, to have correct metadata, for distributions like
# Fedora which don’t keep old packages around. If you don’t like this checking
# interupting your command line usage, it’s much better to have something
# manually check the metadata once an hour (yum-updatesd will do this).
# PUT YOUR REPOS HERE OR IN separate files named file.repo
# in /etc/yum.repos.d
As you can see, our local apt-cacher-ng VM is 10.1.1.12.
Run yum update and check your apt-cacher-ng’s cache – you should now see some CentOS respositories cached there.
If you’re looking to add something to the /etc/sudoers file in a Debian Wheezy install, you may find that the file isn’t there! To create the file while logged in as the root user you need to install the sudo package:
apt-get install sudo
Once that install completes the file will appear:
# This file MUST be edited with the ‘visudo’ command as root.
# Please consider adding local content in /etc/sudoers.d/ instead of
# directly modifying this file.
# See the man page for details on how to write a sudoers file.
# Host alias specification
# User alias specification
# Cmnd alias specification
# User privilege specification
root ALL=(ALL:ALL) ALL
# Allow members of group sudo to execute any command
%sudo ALL=(ALL:ALL) ALL
# See sudoers(5) for more information on “#include” directives: