Eww. Yeah that was a crap answer, but codeplex, the example in question, did in fact used to be a decent code-sharing/tutorial site for some topics. That said, I don't think it's unreasonable to diff all on-site links against the chrome "malicious site" list if that's publicly accessible on a weekly or monthly basis. @Fabby
I have a tar archive and I need to extract the contents of a directory into another directory.
So for example the content may be located in /home/me/stuff/ and everything in the stuff folder should be extracted to /extract.
Thoughts?
It surprised me, because normally UL has higher level questions unless someone is trolling tagging as Ubuntu, and the data recovery tag is completely misplaced.
The Federal Court for Administrative Affairs ruled that the German civil foreign intelligence service may continue its strategic bulk data collection at De-CIX. :-(
…though mostly due to a technicality. It didn't rule whether the data collection itself was legal, only that the operator must comply with the ministry's order for such data collection.
Police in Brandenburg didn't stop a football fan club's victory party because they didn't recognise the connection between the fans' hoods and those of the KKK:
"Aufstieg" means "rise". Its obvious reference is to the rise to a superior football league in the upcoming season, but the entire line "Rise of the Evil" is kind of incongruent with that.
I get that docker has some overhead and I wouldn't expect it to be as fast as local bin, but 2 seconds overhead? It seems too much ... Once the container is running, the execution itself seems the same.
$ time docker-compose run --rm php-cli php -i > /dev/null
docker-compose run --rm php-cli php...
Ha. grep is faster. cat ../Posts.xml ../Comments.xml | tr '[:upper:]' '[:lower:]' | grep -Ff smokey/blacklisted_websites.txt. Doesn't do quite a much cleaning up after itself but 16 seconds is going to be hard to beat.
@Oli Why not grep -iFf [pattern file] Posts.xml Comments.xml? Is piping through tr actually faster than case-insensitive patterns and, if so, how did you measure?
@Oli Good to know. I didn't know that fixed case-insensitive strings are so slow in GNU grep considering that the Boyer-Moore algorithm used for fixed strings can be easily extended to work case-insensitively with little performance penalty.
I implemented faster "inexact" string matches like that as an exercise for a uni course.
Proper pattern analysis should give a big performance gain here since the "haystack" for the search is relatively large.
@dessert Considering that I did this as an exercise based on well-known published algorithms I'm sure that people with more experience in this stuff are already involved in the development of GNU Grep but decided against this specific change.
@DavidFoerster No one ever bothered submitting a patch because it does exactly what it needs to do for their use case, so if you have something better, submit a patch and then we'll be able to say in 20 years: *Remember when we used to call this dude David and now we have to call him "Herr Doktor Förster"???"
There are two man pages about the sync tool:
(1) http://man7.org/linux/man-pages/man1/sync.1.html
NAME
sync - Synchronize cached writes to persistent storage
SYNOPSIS top
sync [OPTION] [FILE]...
DESCRIPTION top
Synchronize cached writes to pers...
I followed this guide (https://mobiarch.wordpress.com/2014/05/16/creating-an-init-script-in-ubuntu-14-04/) to create a startup script that mounts my shared windows folder and starts my vpn. However, the script is still not working on startup. I am currently using vm virtualbox to emulate Ubuntu 1...
I am trying to run a docker dns server (sameersbn/bind) on ubuntu 18.04, but when starting the container it tells me that port 53 is already in use.
docker: Error response from daemon: driver failed programming external connectivity on endpoint bind (5e620c3c1ac65fbfe28e7d558d10dc9400dd1298957df...
@Videonauth no, find processes every option individually, so -type d -empty first makes a list of every directory and then tests for empty ones while -empty -type d does the same the other way around
@Videonauth One should always think thrice before combining root permissions and find’s -delete option in general I suppose.
You can take advantage of the rmdir command's refusal to delete non-empty directories, and thye find --depth option to traverse the directory tree bottom-up:
find . -depth -exec rmdir {} \;
(and ignore the errors), or append 2>/dev/null to really ignore them
rm -rf will delete all the f...
The packages website currently only lists packages for Cosmic.
For example, https://packages.ubuntu.com/search?keywords=xserver-xorg-core shows results for Cosmic only: https://archive.is/v9q7q. When I click on Xenial, I get no results: https://archive.is/ZdtDd.
The package xserver-xorg-core definitely exists in Xenial:
xserver-xorg-core:
Installed: (none)
Candidate: 2:1.18.4-0ubuntu0.7
Version table:
2:1.18.4-0ubuntu0.7 500
500 http://mirror.atlantic.net/ubuntu xenial-updates/main amd64 Packages
500 http://mirror.atlantic.net/ubuntu xenial-security/main amd64 Packages
2:1.18.4-0ubuntu0.2 0
100 /var/lib/dpkg/status
2:1.18.3-1ubuntu2 500
500 http://mirror.atlantic.net/ubuntu xenial/main amd64 Packages
pkg-website
Undecided / New
but it’s fixed apparently, I just used the wrong package name ;)
code {
font-family: Consolas,Menlo,Monaco,Lucida Console,Liberation Mono,DejaVu Sans Mono,Bitstream Vera Sans Mono,Courier New,monospace,sans-serif;
background-color: #eff0f1
}
$ time find / -type d -empty &>/n
real 2m28.114s
user 0m1.040s
sys 0m4.984s
$ time find / -empty -type d &>/n
real 2m25.704s
user 0m1.004s
sys 0m3.376s
@dessert yeah, it's basically the same. Those differences are well within the margin of error. Also note that running the same command again will be muuuuch faster.
$ time find / -type d -empty &>/n
real 3m39.253s
user 0m1.028s
sys 0m4.764s
$ time find / -empty -type d &>/n
real 2m56.804s
user 0m1.144s
sys 0m4.260s
I m trying to write a shell script and assign the output of a command to a variable. Altough I have found quite some things online, nothing seems to work
could somebody tell me what I am doing wrong?
#!/bin/bash
while true; do
result = $(cat /proc/net/udp | grep 2348)
done
that’s simply a sh shell which gets two arguments, the first being $tmpdir and the second being the filename, ${1##*/} is parameter expansion (substring removal) and removes everything to the last slash from the filename
E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.
fab-root@fab-ux-predator:~
$ sudo dpkg --configure -a
Setting up python3-apport (2.20.1-0ubuntu2.18) ...
dpkg: error processing package apport (--configure):
package is in a very bad inconsistent state; you should
reinstall it before attempting configuration
Errors were encountered while processing:
apport
fab-root@fab-ux-predator:~
$
I can't update my system because it freezes while installing a third-party update (zramswap-enabler)!
Sometimes I get the following message in Update manager:
Could not initialize the package information An unresolvable problem occurred while initializing the package information.
Please...
well it also worships me and sends me the energy from the souls of the condemned certain sources so that I gain more and more power in a more and more evil way every day
3
but it's pain :/
and i really didn't filter the lists too well, it literally is just a namedump from behind the name .com
and the new VM that was just created was given the name 'sveta-bionic' so I mean i really don't control it :/
> This script requires Python 3.6 (because I'm lazy and like new things) and the requests and tqdm libraries. On Ubuntu 18.04, getting up and running is as simple as:
i have a server that receive information about a network, ssid, psw, WPA,...,ip, subnetmask gateway DNS. My problem is i don't know how to tell ti Ubuntu to take infos to trying to connect to network. Something like exec(mcli dev ssid psw WPA ip subnet gateway DNS). Someone Can help me? Code exa...
I am using Ubuntu 16 LTS Server. I have a user with sudo privileges on it. When I attempt to switch from my current user to root, it asks for my password. I enter the correct password and it refuses my password.
username@server:/# sudo su
[sudo] password for username:
Sorry, try again.
[sudo] pa...