text
stringlengths 36
35k
| label
class label 2
classes | source
stringclasses 3
values | tokens_length
int64 128
4.1k
| text_length
int64 36
35k
|
---|---|---|---|---|
Swift Delegate Not Being Called. <p>I have a view with a delegate that I want to have call numpadView(numpadView:) in GameController upon button press, however I can't get it to work. The overload of touchesBegan() works fine, it's really the line with pressDelegate?.numpadView(self) which doesn't call the delegate function in the GameController class. I'm stumped as to what's missing to get it to work?</p>
<p>I cleaned the code to leave only the essential related to the problem for simplicity.</p>
<p><strong>NumpadView.swift</strong></p>
<pre><code>protocol NumpadPressDelegateProtocol {
func numpadView(numpadView: NumpadView)
}
class NumpadView: UIButton{
var pressDelegate: NumpadPressDelegateProtocol?
init(char: Character) {
let frame = CGRectMake(160, 100, 50, 50)
super.init(frame:frame)
self.setTitle("\(char)", forState: UIControlState.Normal)
self.userInteractionEnabled = true
}
override func touchesBegan(touches: NSSet, withEvent event: UIEvent) {
pressDelegate?.numpadView(self)
}
}
</code></pre>
<p><strong>GameController.swift</strong></p>
<pre><code>class GameController: NumpadPressDelegateProtocol {
func numpadView(numpadView: NumpadView) {
//do something
}
}
</code></pre>
| 0non-cybersec
| Stackexchange | 395 | 1,255 |
React how to render page after query change in URL. <p>I'm facing a problem :</p>
<p>I access a URL, for example:</p>
<p><a href="http://localhost:900/user" rel="nofollow noreferrer">http://localhost:900/user</a> </p>
<p>In my page i have an array. When I click on an pagination button for change page in array, my fonction changePage is called, the URL changes for add search query, my page re render because i use setState({page}), so far so good. New URL : <a href="http://localhost:900/user?page=2" rel="nofollow noreferrer">http://localhost:900/user?page=2</a> (Attention the pathname has not changed, i just add search query) </p>
<p>If i click on next page again, the url change to <a href="http://localhost:900/user?page=3" rel="nofollow noreferrer">http://localhost:900/user?page=3</a> and my page re render. It's perfect.</p>
<p>Now, i press the back button in the Browser, the location changes back to <a href="http://localhost:900/user?page=2" rel="nofollow noreferrer">http://localhost:900/user?page=2</a> but the page does not re render.</p>
<p>How to re render page if user press the back button in the Browser and not on the last page on application ?</p>
<p>I use :<br>
react : "16.3.2",<br>
react-dom : "16.3.2",<br>
react-redux : "5.0.7",<br>
react-router-dom : "4.2.2",</p>
<p>EDIT:
when i use listen function after create BrowserHistory, and i press previous browser page: </p>
<pre><code>const history = createBrowserHistory();
history.listen((location, action) => {
// location is an object like window.location
console.log(action, location.search);
});
</code></pre>
<p>the location.search was good. </p>
<p>My problem is only when i use the arrows of the browser in the same page. When i go in other page and i go back to the page, the url is good to and my array is reload with the good informations</p>
| 0non-cybersec
| Stackexchange | 604 | 1,852 |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange | 349 | 1,234 |
Missing dependencies to install net-snmp. <p>This is set up on <strong>CentOS 7</strong></p>
<p>I was trying to install net-snmp via rpm (our yum wont work at all). so I gathered the following rpm packages: (all from the centos updates repository)</p>
<pre><code>net-snmp
net-snmp-utils
net-snmp-libs
net-snmp-agent-libs
</code></pre>
<p>I was able to install <strong>net-snmp-utils</strong> and update <strong>net-snmp-libs</strong>, but when it comes to installing <strong>net-snmp-agent-libs</strong> I need:</p>
<pre><code>libmysqlclient.so.18()(64bit)
libmysqlclient.so.18(libmysqlclient_18)(64bit)
</code></pre>
<p>Which is included on the <strong>mariadb-libs</strong> package.</p>
<p>The problem is the they created a custom repo to install <strong>MariaDB 10.1.41</strong>. The version on the <em>packages site</em> and <em>default repository</em> is <strong>5.5</strong> which is a total conflict on what the system already has. I need these two dependencies to install and setup SNMP on our server, is there any way to install them without affecting the existing database?</p>
<p>I'm running out of ideas and this is the only server left without monitoring. Thanks!</p>
| 0non-cybersec
| Stackexchange | 374 | 1,188 |
NSV: Insufficient butt fat for medical procedure. Sup loseit. Long-time lurker. 5'7" 36M, from 203 to 156 lbs over 7 months. 155 GW (SO CLOSE). Physically I look quite skinny now - slimmer than my BMI would imply because I have a very broad chest and shoulders.
Recently I needed to have some hormonal pellets inserted. They go in the butt cheek. Doctor said it would take 15 minutes, with pain comparable to a dental shot - unpleasant but not that bad. I donned the stylish hospital gown, then lay on the operating table while chit-chatting with the nurse. She applied some topical.
The doctor comes in. First time he's seen me undressed. "My, you are a skinny one" he comments. (Nobody has EVER said that to me before!) He begins the procedure - injecting anesthetic, slicing me open with a scalpel, then using a trocar to place the pellets.
It hurt like a motherfucker. Worst pain of my life. I barely held it together.
Afterwards, he told me, most people have a nice subcutaneous fat layer. But I didn't have enough fat. He had to go through muscle, and that's why it hurt so damn much.
Yay? 😬
Anyways I thought it was a funny NSV, though my ass isn't laughing. | 0non-cybersec
| Reddit | 303 | 1,172 |
What is the proper way to return from an exception in Scala?. <p>In a non-functional language, I might do something like:</p>
<pre><code>try {
// some stuff
} catch Exception ex {
return false;
}
// Do more stuff
return true;
</code></pre>
<p>In Scala, however, this pattern is clearly not correct. If my scala code looks like this:</p>
<pre><code>try {
// do some stuff
}
catch {
case e: Exception => // I want to get out of here and return false
)
}
// do more stuff
true
</code></pre>
<p>How do I properly do that? I don't want to use the "return" statement, of course, but I also don't want to drop through and "do more stuff" and eventually return true.</p>
| 0non-cybersec
| Stackexchange | 217 | 684 |
How to disable script debugging in Visual Studio 2010 when running Asp.Net website project?. <p>I'm creating a website in Visual Studio 2010. I would like to use Visual Studio for C# debugging, without using it as JavaScript debugger. <strong>Is there a way to disable script debugging for Asp.Net website projects?</strong> I run my projects by hitting F5 in my Visual Studio.</p>
<p>(I've noticed that when I attach the debugger manually, I can specify the type of stuff I would like to debug.)</p>
<p>Note: <strong>I would like to debug JavaScript, but not with Visual Studio 2010. The Developer Toolbar will suffice.</strong></p>
| 0non-cybersec
| Stackexchange | 157 | 636 |
differences between make_unique and make_shared when handling arrays. <p>as of C++17 you can use <code>make_unique</code> in order to create smart pointers to arrays, such as:</p>
<pre><code>unique_ptr<int[]> ptr = make_unique<int[]>(10);
</code></pre>
<p>which will create a smart pointer to an array of 10 elements (the fact that proper deleter[] will be called is also great). </p>
<p>However according to <a href="https://en.cppreference.com/w/cpp/memory/shared_ptr/make_shared" rel="nofollow noreferrer">this</a> <code>make_shared</code> does not support such functionality (at least not in C++17, to my understanding):</p>
<pre><code>shared_ptr<int[]> ptr = make_shared<int[]>(10);
</code></pre>
<p>the code above is apparently illegal. Indeed, my Visual Studio 2017 (v141) spits out the following error: </p>
<pre><code>C2070: 'int[]': illegal sizeof operand'
</code></pre>
<p>What's interesting is that <code>shared_ptr</code> itself does support array types (i.e., <code>shared_ptr<int[]></code> is <a href="https://en.cppreference.com/w/cpp/memory/shared_ptr/make_shared" rel="nofollow noreferrer">legal</a>), but <code>make_shared</code> does not. Whereas <code>make_unique</code> does. </p>
<p>The question is, what prevented the standard maker people to let <code>make_shared</code> support array types, just like in the case of <code>make_unique</code>? </p>
| 0non-cybersec
| Stackexchange | 467 | 1,411 |
Showing more song information on the Music app. There are so many options iTunes gives you to fill in for a song: year, composer, genre, disc number, bpm, but what's the point of it all? Unless you're going to make a playlist based on any of these things they don't seem to be relevant or show up anywhere when actually listening to the song to my knowledge.
Is there any way to show some of this information just in your library on the Music app or when you're listening to a song on your phone? I'd love to be able to see the year of every song on my library when scrolling through or when the song being played in the music bar with the artist, album, and song name. | 0non-cybersec
| Reddit | 155 | 671 |
Show that if Y is transcendental over a field K, and F is a field with $K\subset F\subset K(Y)$ and $K\neq F$ then Y is algebraic on F. <p>I have the following problem:</p>
<blockquote>
<p>Show that if Y is transcendental over a field K, and F is a field with <span class="math-container">$K\subset F\subset K(Y)$</span> and <span class="math-container">$K\neq F$</span> then Y is algebraic on F</p>
</blockquote>
<p>I know there are infinite fields of such type, for example <span class="math-container">$K[Y^i]$</span> has Y as an algebraic element <span class="math-container">$\forall i \in \mathbb{N}$</span>
However I don't know how to prove this in the general case. This question was proposed in my Galois theory exam last year. Any ideas on how to solve it? </p>
| 0non-cybersec
| Stackexchange | 240 | 776 |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange | 349 | 1,234 |
Protractor E2E angular "angular could not be found on the window". <p>I have a strange error after running my tests in angular project <code>Error: Error while waiting for Protractor to sync with the page: "angular could not be found on the window"</code>. My Protractor configuration looks like this: </p>
<pre><code>require('coffee-script').register();
exports.config = {
seleniumServerJar: './node_modules/protractor/selenium/selenium-server-standalone-2.39.0.jar',
seleniumAddress: 'http://localhost:4444/wd/hub',
capabilities: {
browserName: 'chrome'
//'chromeOptions': {
// 'args': ['--disable-extensions']
//}
},
specs: [
'*_spec.coffee'
],
allScriptsTimeout: 10000000000,
baseUrl: 'http://localhost:9003/',
jasmineNodeOpts: {
isVerbose: false,
showColors: true,
includeStackTrace: true,
defaultTimeoutInterval: 10000000000
}
};
</code></pre>
<p>And test:</p>
<pre><code>loginPage = require './pages/log_in_page'
describe 'Log In', ->
it 'shows after login', ->
loginPage()
.setEmail('[email protected]')
.setPass('a46s75d4as765d4a6s7d54as76d5as74das76d5')
</code></pre>
<p>Get info from page:</p>
<pre><code>module.exports = ->
@email = element By.css '.test-i-login'
@password = element By.css '.test-i-password'
@setEmail = (name) =>
@email.sendKeys(name)
this
@setPass = (number) =>
@password.sendKeys(number)
this
this
</code></pre>
<p>There're some similar issues on github, but there I didn't find a solution working for me. Thx for answering.</p>
| 0non-cybersec
| Stackexchange | 555 | 1,651 |
Time stamp for pictures actually taken before being sent to recipient on iphone. <p>My boyfriend sent me a picture from his Iphone 6, I have an iphone 5. I wanted to know if it was possible to find out when the picture was actually taken, not just sent to me or saved on my own iphone. Is there any way to find this out? I have used certain apps to find out with no luck. They only show me when I saved the picture sent to my phone or when he sent the picture to me in a text. Does anyone know?</p>
| 0non-cybersec
| Stackexchange | 132 | 504 |
An aplication of the Hahn-Banach separation theorem: multiplier rule. <p>In convex analysis optimization, I would like to show that the necessary conditions of the multiplier rule correspond to the nonexistence of a decrease direction. I would like to prove the following theorem:</p>
<p><strong>Theorem:</strong> Let <span class="math-container">$\{\zeta_i : i = 1,2,...,k \}$</span> finite subset in <span class="math-container">$X^{*}$</span> - dual space of the normed space <span class="math-container">$X$</span>. The following are equivalent:</p>
<p><span class="math-container">$(a)$</span> There is no <span class="math-container">$v \in X$</span> such that <span class="math-container">$\langle \zeta_i , v \rangle < 0 , \forall i = 1,...,k$</span>;</p>
<p><span class="math-container">$(b)$</span> The set <span class="math-container">$\{\zeta_i : i = 1,2,...,k \}$</span> is positively linearly dependent : there exists a nonzero nonnegative vector <span class="math-container">$\gamma \in \mathbb{R}^k$</span> such that <span class="math-container">$\sum_{1}^{k} \gamma_i \zeta_i = 0$</span>.</p>
<p><span class="math-container">$\quad$</span> To prove <span class="math-container">$(a) \implies (b)$</span>, I will construct two subsets and I try to use the separation theorem. Before, I enunciate such theorem:</p>
<p><strong>(Hahn-Banach separation theorem)</strong></p>
<p><em>Let <span class="math-container">$K_1$</span> and <span class="math-container">$K_2$</span> be nonempty, disjoint
convex subsets of the normed space <span class="math-container">$X$</span>. If <span class="math-container">$K_1$</span> is open, then the sets can be separated. That is, there exist <span class="math-container">$\gamma$</span> ∈ <span class="math-container">$X^{*}$</span> and <span class="math-container">$\eta$</span> ∈ R such that
<span class="math-container">$$\langle \gamma , x \rangle < \eta \leq \langle \gamma , y \rangle, \quad \forall x \in K_1 , y \in K_2.$$</span></em></p>
<p>To apply the separation theorem, let</p>
<p><span class="math-container">$$K_1 = \{y \in \mathbb{R}^k : y_i < 0, \forall i\}, \quad K_2 = \{ (\langle \zeta_1 , v \rangle , ..., \zeta_k , v \rangle) : v \in X \}$$</span></p>
<p>The sets <span class="math-container">$K_1 , K_2$</span> are both convex and nonempty. By <span class="math-container">$(a)$</span> the sets are disjoint. Then, by the separation theorem, exist <span class="math-container">$\eta \in \mathbb{R}$</span> and <span class="math-container">$\gamma \in \mathbb{R}^k$</span>. It is straightforward show that <span class="math-container">$\eta = 0$</span> and</p>
<p><span class="math-container">$$ 0 \leq \sum \gamma_i \langle \zeta_i , v \rangle, \quad \forall v \in X.$$</span></p>
<p>I can't show the nonnegative of <span class="math-container">$\gamma$</span> and the other inequality</p>
<p><span class="math-container">$$ 0 \geq \sum \gamma_i \langle \zeta_i , v \rangle, \quad \forall v \in X.$$</span></p>
<p>Some help?</p>
| 0non-cybersec
| Stackexchange | 978 | 3,011 |
Increase number of recent files in Mint start menu. <p>The Cinnamon start menu only shows up to 20 items under "Recent Files", how do I increase this limit?</p>
<p>I want to do this because typing a search term into the start menu search bar only considers these 20 items, so it is often unable to find the file I'm looking for.</p>
<p>Further info:</p>
<ul>
<li>searching for "recent" in <code>dconf-editor</code> did not bring up any relevant settings</li>
<li><code>nemo</code> (file manager) shows way more items in its "Recent" list (for me it's currently 586, this seems to be limited to exactly 1 month)</li>
</ul>
| 0non-cybersec
| Stackexchange | 181 | 625 |
Is there a way to manage and sort lots of wireless networks on OS X?. <p>On OS X you can manage your wireless networks; that is drag them to set preferred order, delete ones you don't want any more, etc.</p>
<p>The only problem is that there is a tiny window which only shows ~4 networks at a time.</p>
<p>Is there some way to be able to see more of the networks at once, and perhaps sort by name?</p>
<p><img src="https://i.stack.imgur.com/UdrYG.jpg" alt="enter image description here"></p>
| 0non-cybersec
| Stackexchange | 145 | 495 |
Auslander-Reiten-Quivers of representation-finite algebras having different 3-dimensional forms. <p>I am looking for references, where I can find (pictures of) connected Auslander-Reiten-Quivers of representation-finite $k$-algebras ($k$ is a (preferably, but not necessarily finite) field) with one or more of the following properties:</p>
<p>1) the Auslander-Reiten quiver contains two cylinders (so, there are periodic modules), but also many non-periodic modules</p>
<p>2) the Auslander-Reiten quiver contains a Moebius strip, but also many non-periodic modules</p>
<p>In the first case, I was thinking of something like</p>
<p><a href="https://i.stack.imgur.com/Zmfsp.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Zmfsp.png" alt="enter image description here"></a></p>
<p>where the colored modules are identified...but with 2 cylinders (I should have added the second one at the top of the non-Tau-periodic modules)...and in the second case, I was thinking of something like </p>
<p><a href="https://i.stack.imgur.com/6UpzP.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/6UpzP.png" alt="enter image description here"></a></p>
<p>But, I'm not sure, if any of these can happen...</p>
<p>Thanks for the help!</p>
<p>EDIT: Having some algebras as examples, but without the pictures, would also be nice. </p>
| 0non-cybersec
| Stackexchange | 416 | 1,359 |
How to increase the playback speed of a recorded WebEx meeting?. <p>My company records WebEx meetings. Playing them back usually starts in IE and then jumps to a standard WebEx client (showing the shared screen and participants list), and also has the playback controls (play, stop, volume, slider), and a table of contents window (where you can navigate / jump between slides).</p>
<p>Is there any way to increase the playback speed of the meeting (like how Youtube now allows you to play .25, .50, Normal, 1.25, 1.50, and 2.0 times the speed)? If so, how?</p>
| 0non-cybersec
| Stackexchange | 146 | 565 |
Visual studio 2015 not removing pending changes immediately after a check-in (TFS 2015). <p>When my team and I were on visual studio 2013, after successfully checking in our pending changes, the files that were checked in would be removed from the pending changes window. </p>
<p>Ever since upgrading to 2015, we have lost this functionallity. Now, after a successfuly check in, the pending changes will remain in the pending changes window until they are manually undone or and identical check in is undertaken in which case all of the files will sync themselves with source control and will no longer be pending changes. </p>
<p>When diffing the files with their counterparts in source control after a successful check in, it is clear that there are no changes between the two despite the fact they are still in the pending changes window. Is it possible that we have overlooked a simple setting that allows us to sync with TFS immediatelyafter a check in?</p>
<p>Thanks</p>
| 0non-cybersec
| Stackexchange | 218 | 980 |
Schönhage-Strassen multiplication. <p>I am trying to implement the Schönhage-Strassen algorithm (SSA) for multiplying large integers, but it only gives the right result if all $\delta_j$ are zero. I'll explain what I mean by this:</p>
<p>SSA (as described in the original 1971 paper <em><a href="http://www.scribd.com/doc/68857222/Schnelle-Multiplikation-gro%C3%9Fer-Zahlen" rel="nofollow">Schnelle Multiplikation großer Zahlen</a></em>) basically works like this:</p>
<ol>
<li>Let $a$ and $b$ be two integers to multiply.</li>
<li>Determine $n$. Roughly speaking, $n$ will be about $\frac12 \log_2 \log_2 \max(a,b)$</li>
<li>Compute integers $z_j$ such that $a\cdot b=\sum\limits_j z_j\cdot2^{j\cdot2^{n-1}}$, as follows:
<ol>
<li>Compute $\xi_j\equiv z_j \pmod {2^{2^n}+1}$; this step performs an FFT+iFFT</li>
<li>Compute $\eta_j\equiv z_j \pmod {2^{n+2}}$</li>
<li>Compute $z_j$ from $\xi_j$ and $\eta_j$:
<ol>
<li>$\delta_j\equiv\eta_j-\xi_j \pmod {2^{n+2}}$ <strong><--- THIS IS THE $\delta_j$ MENTIONED ABOVE</strong></li>
<li>$z_j=\xi_j+\delta_j(2^{2^n}+1)$</li>
</ol></li>
</ol></li>
<li>Output $\sum\limits_j z_j\cdot2^{j\cdot2^{n-1}}$</li>
</ol>
<p>I tested the other parts of the code, and I even did a a complete example with pencil and paper. Plus, everything works when $\delta=0$, so I'm pretty certain the problem is in step 3.3 or 4.</p>
<p><a href="http://en.wikipedia.org/wiki/Sch%C3%B6nhage%E2%80%93Strassen_algorithm" rel="nofollow">Wikipedia</a> doesn't go into enough detail to even mention $\xi_j$ and $\eta_j$.</p>
<p>Does anyone know of a working example, sample code, or other information that might help me track down the problem?</p>
<p>Edit: I will put the code online if I get it to work.</p>
<p>Edit 2: I uploaded some Java code <a href="http://pastebin.com/7QbXtEjM" rel="nofollow">here</a>. It runs as a regular Java program; the output shows one working example and one that doesn't work. Computation of $\delta,\xi,\eta,z_r$ happens in lines 148-160.</p>
<p>Also, there is a modified version <a href="http://pastebin.com/YEBE1s43" rel="nofollow">here</a> which uses much smaller input values, but I head to tweak the code so it handles pieces less than one byte.</p>
| 0non-cybersec
| Stackexchange | 819 | 2,222 |
Implementation-independent floating-point/integer conversions. <p>Suppose <code>I</code> is some integer type and <code>F</code> some (real) floating point type.</p>
<p>I want to write two functions. The first function shall take a value <code>i</code> of type <code>I</code> and return a boolean indicating whether <code>i</code> converted to <code>F</code> falls into the representable range, i.e. whether <code>(F)i</code> will have defined behavior.</p>
<p>The second function shall take a value <code>f</code> of type <code>F</code> and return a boolean indicating whether <code>f</code> converted to <code>I</code> falls into the representable range, i.e. whether <code>(I)f</code> will have defined behavior.</p>
<p>Is it possible to write such a function that will be, on every implementation conforming to the standard, correct and not exhibit undefined behavior for any input? In particular I do not want to assume that the floating point types are IEEE 754 types.</p>
<p>I am asking about both C and C++ and their respective standard versions separately, in case that changes the answer.</p>
<p>Basically the intention of this question is to figure out whether (sensible) floating-point / integral conversions are possible without relying on IEEE 754 or other standards or hardware details at all. I ask out of curiosity.</p>
<p>Comparing against e.g. <code>INT_MAX</code> or <code>FLT_MAX</code> does not seem to be possible, because it is not clear which type to do the comparison in without already knowing which of the types has wider range.</p>
| 0non-cybersec
| Stackexchange | 412 | 1,567 |
Dimension of a phase space. <p>Consider the differential equation
<span class="math-container">$\dot x=v(t,x).$</span><br>
Is the phase space dimension two here? Cuz <span class="math-container">$x$</span> and <span class="math-container">$t$</span>, both are required to determine <span class="math-container">$\dot x$</span>, all of which then specify the state of the system uniquely.</p>
<p>Now consider <span class="math-container">$\dot x=v(x).$</span><br>
Is the dimension one here? Cuz we only need to specify <span class="math-container">$x$</span> for the system to know its state uniquely. (It’s invariant under <span class="math-container">$t$</span>-translations.)</p>
| 0non-cybersec
| Stackexchange | 206 | 683 |
When solving an ODE using power series method, Why do we need to expand the solution around the singular point?. <p>When solving a differential equation using series expansion method, if it has the following form :</p>
<p>$$y''+\frac{p(x)}{x}y'+\frac{q(x)}{x^2}y=0$$</p>
<p>; where $p$ and $q$ are analytic at $x_0$; if we want to find the solution in a series fprm expanded around $x_0$, it can't be solved using the regular method of series expansion and we must use Frobenius method to find the series around $x_0$.</p>
<p>Why do we need to expand around the singular point? why we don't solve the equation by expanding $y$ around a regular, nonsingular point (I mean a point different than $x_0$) and without using Frobenius method ? Is it a matter of convergence of the solution series at the singularity point?</p>
| 0non-cybersec
| Stackexchange | 236 | 826 |
What is the $n$ th derivative of $\ln(x)/(1+x^2)\:?$. <p>I'm into something but I came across the problem of finding a closed form for</p>
<p><span class="math-container">$$\left( \frac{\ln x}{1+x^2} \right)^{(n)}$$</span></p>
<p>where the little <span class="math-container">$(n)$</span> denotes the <span class="math-container">$n$</span> th derivative of the function. After looking in some softwares, I believe the closed form is a rational function with <span class="math-container">$\ln x$</span> as a factor.</p>
<p>Thank for any help.</p>
<p>Edit: I found a way to change the problem above to this one:</p>
<p><span class="math-container">$$ \left( \frac{\partial }{\partial x}\frac{(1-x)}{(1+x^2)(1-(1-x)y)}\right)^{(n)}$$</span></p>
<p>maybe this is easier?</p>
<p>EDIT <span class="math-container">$2$</span>: I said closed formula but forgot to mention something easy to handle, and a summation like <span class="math-container">$\sum_{k=0}^n \cdots$</span> is hard, because after finding the derivative I'll need to find it's maximum...</p>
<p>A good example of what I mean <a href="https://math.stackexchange.com/questions/2950916/finding-the-2n1-th-derivative-of-fracy2n1xy1-x2y2-with-respect-t">Finding the $2n+1$ th derivative of $\frac{y^{2n+1}xy}{1-x^2y^2}$ with respect to $x$.</a></p>
<p>I'm trying to establish the irrationality of a constant using Beuker's integrals, and using this approach you'll eventually need to find the <span class="math-container">$n$</span> th derivative of a function. In this case it can be either the first function or the second showed here. The <span class="math-container">$y$</span> in the second came from a substitution in the Beuker's integral.</p>
| 0non-cybersec
| Stackexchange | 563 | 1,717 |
how to attach (mount) VHD which is currently used by Hyper-V VM to the host?. <p>I want to be able to read data from the Hyper-V VMs on the host. I understand I can go to DISM and attach VHD there - but it requires a VM to be offline - otherwise I get the following error:</p>
<blockquote>
<p>Virtual Disk Manager</p>
<p>The process cannot access the file because it is being used by another process. </p>
</blockquote>
<p>Are there any ways to achieve this while keeping VM online? I want this primary for making backups easier.</p>
| 0non-cybersec
| Stackexchange | 154 | 543 |
What is needed to prove the consistency of Tarski's Euclidean geometry?. <p>This question might be too elementary for MO, in which case I would gladly move it to math.stackexchange.com </p>
<p>Consider <a href="https://en.wikipedia.org/wiki/Tarski's_axioms">Tarski's axiomatization</a> of Euclidean Geometry. It is stated in the wikipedia page linked and many other places that Tarski proved this first-order theory to be complete and consistent. My question concerns consistency: the proofs I have seen in model-theoretic literature reduce to the triviality that Euclidean geometry has a model in set theory (namely $\mathbb R^2$), so these proofs are actually proofs of the relative consistency of Euclidean Geometry with respect to set theory. But surely there must be a proof of the consistency of Tarski's axioms using only a considerably less powerful theory than set theory (whose consistency may itself be in doubt). </p>
<blockquote>
<p>What (hopefully weak) meta-theory is needed to prove that Tarski's axioms are consistent? </p>
</blockquote>
<p>For example, what about Tarski's original proof (that I can't track down on the internet)? Or perhaps more recent proofs? More philosophically, is there a proof of the consistency of these axioms that Hilbert would call <em>finitist</em>?</p>
| 0non-cybersec
| Stackexchange | 332 | 1,314 |
external disk formated with NTFS not working on Mac. <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="https://apple.stackexchange.com/questions/10628/hard-drive-read-only-access-with-mac">Hard drive read only access with Mac</a> </p>
</blockquote>
<p>I bought new 1 TB <strong>WD My Passport</strong> and format it with NTFS on windows XP. and now when I connect it on mac, I see the drive but I cant add files to it.</p>
<p>what is the issue?</p>
<p>Thanks,</p>
| 0non-cybersec
| Stackexchange | 167 | 490 |
My biggest visual turn-on is my husband's erect cock straining against his boxers. What visuals really get you going?. My husband is an incredibly sexy man, face and body-wise, so of course looking at him is a turn-on in general. But one thing that gets me going like none other is simply seeing him with a boner in nothing but his underwear. He favors this style of boxers: http://www.hisroom.com/hanes-7460p4-comfort-soft-waistband-boxer-brief-4-pack.shtml ...kinda form-fitting.
When I see him approach me with his hard cock straining against the fabric, it drives me wild. I can't resist getting my face down there to rub up against him, feeling the hardness and smelling his pre-cum through the fabric. Then I get to unwrap his dick and lick it and suck it and devour it like the delicious treat it is. Oh my!!!
Ahem...so, what sights really get YOUR juices flowing??
EDIT: just replaced the linked image
| 0non-cybersec
| Reddit | 246 | 929 |
Ubuntu software-center not loading. <p>I have tried loading up the software center in order to install some packages but it doesnt seem to open. I tried entering the following command in terminal:</p>
<pre><code>software-center
</code></pre>
<p>and get the following error:</p>
<pre><code>bash: /usr/bin/software-center: /usr/bin/python: bad interpreter: Permission denied
</code></pre>
<p>Any assistance would be appreciated. I am running on Ubuntu 14.04.</p>
<p>I have also tried uninstalling and reinstalling it using: </p>
<pre><code>sudo apt-get remove software-center
sudo apt-get install software-center
</code></pre>
<p>To no avail. </p>
<p>I also tried <code>sudo apt-get install -f</code> and received the following output: </p>
<pre><code>Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
libntdb1 linux-headers-4.2.0-27 linux-headers-4.2.0-27-generic
linux-image-4.2.0-27-generic linux-image-extra-4.2.0-27-generic python-ntdb
python-support
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 18 not upgraded.
11 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up libglib2.0-dev (2.40.2-0ubuntu1) ...
/var/lib/dpkg/info/libglib2.0-dev.postinst: 6: /var/lib/dpkg/info/libglib2.0-dev.postinst: pycompile: not found
dpkg: error processing package libglib2.0-dev (--configure):
subprocess installed post-installation script returned error exit status 127
dpkg: dependency problems prevent configuration of libatk-bridge2.0-dev:amd64:
libatk-bridge2.0-dev:amd64 depends on libglib2.0-dev (>= 2.4.1-2); however:
Package libglib2.0-dev is not configured yet.
dpkg: error processing package libatk-bridge2.0-dev:amd64 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of libatk1.0-dev:
libatk1.0-dev depends on libglib2.0-dev (>= 2.31.2); however:
Package libglib2.0-dev is not configured yet.
dpkg: error processing package libatk1.0-dev (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of libcairo2-dev:
libcairo2-dev depends on libglib2.0-dev; however:
Package libglib2.0-dev is not configured yet.
dpkg: error processing package libcairo2-dev (--configure):
dependency problems - leaving unconNo apport report written because the error message indicates its a followup error from a previous failure.
No apport report written because the error message indicates its a followup error from a previous failure.
No apport report written because MaxReports is reached already
No apport report written because MaxReports is reached already
No apport report written because MaxReports is reached already
No apport report written because MaxReports is reached already
figured
dpkg: dependency problems prevent configuration of libgdk-pixbuf2.0-dev:
libgdk-pixbuf2.0-dev depends on libglib2.0-dev (>= 2.37.6); however:
Package libglib2.0-dev is not configured yet.
dpkg: error processing package libgdk-pixbuf2.0-dev (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of libpango1.0-dev:
libpango1.0-dev depends on libglib2.0-dev (>= 2.34.0); however:
Package libglib2.0-dev is not configured yet.
libpango1.0-dev depends on libcairo2-dev (>= 1.12.10); however:
Package libcairo2-dev is not configured yet.
dpkg: error processing package libpango1.0-dev (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of libgtk-3-dev:
libgtk-3-dev depends on libglib2.0-dev (>= 2.37.5); however:
Package libglib2.0-dev is not configured yet.
libgtk-3-dev depends on libgdk-pixbuf2.0-dev (>= 2.27.1); however:
Package libgdk-pixbuf2.0-dev is not configured yet.
libgtk-3-dev depends on libpango1.0-dev (>= 1.32.4); however:
Package libpango1.0-dev is not configured yet.
libgtk-3-dev depends on libatk1.0-dev (>= 2.7.5); however:
Package libatk1.0-dev is not configured yet.
libgtk-3-dev depends on libatk-bridge2.0-dev; however:
Package libatk-bridge2.0-dev:amd64 is not configured yet.
libgtk-3-dev depends on libcairo2-dev (>= 1.13.0~20140204); however:
Package libcairo2-dev is not configured yet.
dpkg: error processing package libgtk-3-dev (--configure):
dependency problems - leaving unconfigured
Setting up python-support (1.0.15) ...
/var/lib/dpkg/info/python-support.postinst: 20: /var/lib/dpkg/info/python-support.postinst: update-python-modules: not found
dpkg: error processing package python-support (--configure):
subprocess installed post-installation script returned error exit status 127
No apport report written because MaxReports is reached already
Setting up python-wxversion (2.8.12.1+dfsg-2ubuntu2) ...
/var/lib/dpkg/info/python-wxversion.postinst: 6: /var/lib/dpkg/info/python-wxversion.postinst: pycompile: not found
dpkg: error processing package python-wxversion (--configure):
subprocess installed post-installation script returned error exit status 127
No apport report written because MaxReports is reached already
dpkg: dependency problems prevent configuration of python-wxgtk2.8:
python-wxgtk2.8 depends on python-wxversion (>= 2.6.3.2.2-2); however:
Package python-wxversion is not configured yet.
dpkg: error processing package python-wxgtk2.8 (--configure):
dependency problems - leaving unconfigured
No apport report written because MaxReports is reached already
Setting up software-center (13.10-0ubuntu4.1) ...
/var/lib/dpkg/info/software-center.postinst: 8: /var/lib/dpkg/info/software-center.postinst: pycompile: not found
dpkg: error processing package software-center (--configure):
subprocess installed post-installation script returned error exit status 127
No apport report written because MaxReports is reached already
Errors were encountered while processing:
libglib2.0-dev
libatk-bridge2.0-dev:amd64
libatk1.0-dev
libcairo2-dev
libgdk-pixbuf2.0-dev
libpango1.0-dev
libgtk-3-dev
python-support
python-wxversion
python-wxgtk2.8
software-center
</code></pre>
| 0non-cybersec
| Stackexchange | 1,951 | 6,739 |
Hot take: I think Catcher in the Rye is overrated.. So I know a lot of people will disagree with me but it's fine. If you like the book that's great.
I've had a pretty long history with Catcher in the Rye.
I'm a French Canadian college student so English was my second language (French being the first one obviously). You start learning English at 6 years old since the rest of the entire continent speaks English and a few Canadians make the effort of learning French. I personally really like my English class except for one particular thing: Catcher of the Rye.
Im fully aware it's a classic, "everyone needs to read it once in their lifetime" and I agree with that, but it's getting truly ridiculous.
My English teachers in high school were basically creating some kind of religion out of it. Every YEAR we had to read it to see if our perception of the book had changed. We even did a trip to New York where the main goal was to follow the steps of Holden Caulfield around the city (while reading the book during our trip simultaneously). My perception of the book as then got worst every year, every time I reread it, I get tired of the nonchalance of the main character, the metaphors with the ducks of central park. It has become for me one of the worst book I've ever read cause I'm so fed up with it.
To my surprise, my English teacher in college also wanted us to read it and I just blew up. There are soo much more English classics that we could've read and I think Catcher in the Rye is overrated. My teachers would always say that it's impossible to dislike a book that took so many years to write and I honestly don't see the point.
I wonder if it's the same thing in the reste if Canada/USA or you guys were lucky enough to read something else. I'm starting to think my teachers were just crazy. | 0non-cybersec
| Reddit | 422 | 1,820 |
How to disable camera microphone on AVCapture device input. <p>I am setting a microphone on a <code>AVCaptureSession</code> and I am in need of a switch for the mic. How should I proceed with this?
Do I really need to the <code>captureSession?.removeInput(microphone)</code>, or is there an easies way?</p>
<pre><code>let microphone = AVCaptureDevice.defaultDevice(withMediaType: AVMediaTypeAudio)
do {
let micInput = try AVCaptureDeviceInput(device: microphone)
if captureSession.canAddInput(micInput) {
captureSession.addInput(micInput)
}
} catch {
print("Error setting device audio input: \(error)")
return false
}
</code></pre>
| 0non-cybersec
| Stackexchange | 198 | 735 |
Spring Data Rest Validation Confusion. <p>Looking for some help with Spring data rest validation regarding proper handling of validation errors:</p>
<p>I'm so confused with the docs regarding spring-data-rest validation here: <a href="http://docs.spring.io/spring-data/rest/docs/current/reference/html/#validation" rel="noreferrer">http://docs.spring.io/spring-data/rest/docs/current/reference/html/#validation</a></p>
<p>I am trying to properly deal with validation for a POST call that tries to save a new Company entity</p>
<p>I got this entity:</p>
<pre><code>@Entity
public class Company implements Serializable {
@Id
@GeneratedValue
private Long id;
@NotNull
private String name;
private String address;
private String city;
private String country;
private String email;
private String phoneNumber;
@OneToMany(cascade = CascadeType.ALL, mappedBy = "company")
private Set<Owner> owners = new HashSet<>();
public Company() {
super();
}
</code></pre>
<p>...</p>
<p>and this RestResource dao</p>
<pre><code>import org.springframework.data.repository.PagingAndSortingRepository;
import org.springframework.data.rest.core.annotation.RestResource;
import com.domain.Company;
@RestResource
public interface CompanyDao extends PagingAndSortingRepository<Company, Long> {
}
</code></pre>
<p>POST Request to api/Companies:</p>
<pre><code>{
"address" : "One Microsoft Way",
"city" : "Redmond",
"country" : "USA",
"email" : "[email protected]",
"phoneNumber" : "(425) 703-6214"
}
</code></pre>
<p>When I issue a POST with a null name , I get the following rest response with httpcode 500</p>
<p>{"timestamp":1455131008472,"status":500,"error":"Internal Server Error","exception":"javax.validation.ConstraintViolationException","message":"Validation failed for classes [com.domain.Company] during persist time for groups [javax.validation.groups.Default, ]\nList of constraint violations:[\n\tConstraintViolationImpl{interpolatedMessage='may not be null', propertyPath=name, rootBeanClass=class com.domain.Company, messageTemplate='{javax.validation.constraints.NotNull.message}'}\n]","path":"/api/companies/"}</p>
<p>I tried creating the following bean, but it never seems to do anything:</p>
<pre><code>@Component(value="beforeCreateCompanyValidator")
public class BeforeCreateCompanyValidator implements Validator{
@Override
public boolean supports(Class<?> clazz) {
return Company.class.isAssignableFrom(clazz);
}
@Override
public void validate(Object arg0, Errors arg1) {
System.out.println("xxxxxxxx");
}
}
</code></pre>
<p>and even if it did work, how would it help me in developing a better error response with a proper http code and understandable json response ?</p>
<p>so confused </p>
<p>using 1.3.2.RELEASE</p>
<pre><code><parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>1.3.2.RELEASE</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
</code></pre>
| 0non-cybersec
| Stackexchange | 963 | 3,106 |
vagrant no space left on device. <p>Today I started getting errors on simple operations, like creating small files in <code>vim</code>, the bash completion started to complain as well.</p>
<p>Here is the result of <code>df -h</code> :</p>
<pre><code>vagrant@machine:/vagrant$ df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sda1 40G 38G 249M 100% /
none 4.0K 0 4.0K 0% /sys/fs/cgroup
udev 2.0G 12K 2.0G 1% /dev
tmpfs 396M 396K 395M 1% /run
none 5.0M 0 5.0M 0% /run/lock
none 2.0G 0 2.0G 0% /run/shm
none 100M 0 100M 0% /run/user
overflow 1.0M 148K 876K 15% /tmp
192.168.50.1:/Users/nha/repo/assets 233G 141G 93G 61% /var/www/assets
vagrant 233G 141G 93G 61% /vagrant
</code></pre>
<p>So apparently <code>/</code> doesn`t have space anymore ? Isn't it weird since I have space in the other filesystems (or am I misreading something) ?</p>
<p>How do I get more space on my vm ?</p>
| 0non-cybersec
| Stackexchange | 397 | 1,245 |
how to use event onChange in ionic2. <p>Basically I am trying to make a registration form in which I have some drop down lists. And I want to apply "(change)" event on it which will trigger a function whenever value will be changed or we can say value be selected from that drop down list and based on that I will be assigning next fields dynamically but this event is not working on drop-down while its working fine with text fields.
Can someone help me out with this?</p>
<p>Sample code:</p>
<p>home.html --></p>
<pre><code><ion-header>
<ion-navbar>
<ion-title>Home</ion-title>
</ion-navbar>
</ion-header>
<ion-content padding>
<form [formGroup]="myForm">
<ion-item>
<ion-label>Dropdown1 :</ion-label>
<ion-select formControlName="dd" (ionChange)='f()' #dd>
<ion-option value='1'>A</ion-option>
<ion-option value='2'>B</ion-option>
<ion-option value='3'>C</ion-option>
<ion-option value='4'>D</ion-option>
</ion-select>
</ion-item>
<ion-item>
<ion-label>Dropdown2 :</ion-label>
<ion-select>
<ion-option value='1'>E</ion-option>
<ion-option value='2'>F</ion-option>
<ion-option value='3'>G</ion-option>
<ion-option value='4'>H</ion-option>
</ion-select>
</ion-item>
</form>
</ion-content>
</code></pre>
<p>home.ts --></p>
<pre><code>import { Component } from '@angular/core';
import { NavController } from 'ionic-angular';
@Component({
selector: 'page-home',
templateUrl: 'home.html'
})
export class HomePage {
constructor(public navCtrl: NavController) {
}
function f(){
alert('Value Changed!');
alert(this.myForm.dd);
}
}
</code></pre>
| 0non-cybersec
| Stackexchange | 731 | 1,934 |
TIFU by not wanting to use the toilet in a house full of strangers. So. This actually happened last weekend. I'm a grown man. Father of two kids aged 11 and 6. This July 4th my wife took us all down to the coast for a 3 day July 4th party at the house of a long-time friend of hers. I've met a few of these people once or twice. Acquaintances at best.
Well we arrive Sunday afternoon. Get our tent set up and are hanging out on the porch and have a couple of drinks. I feel the need to take a shit but it isn't an emergency. The bathroom is just off the kitchen where a good number of folks are hanging out prepping food/making drinks. I didn't want to bomb the bathroom within the first few hours of meeting everyone.
About this same time someone mentions that we'll need ice soon. I volunteer to make the run. It should be noted that this house is on the waterfront deep in a residential neighborhood with 15mph streets full of families walking to the beach and kids riding their bikes.
I get just down the road and the stomach cramp hits hard and i realize i've probably made a mistake. But I know, from the way in, just at the head of the neighborhood, to my left, is a store. So I make my way to the intersection.
What I didn't realize is that you can't take a left off the main highway into the store, you have to go down about a mile and make a u-turn. Well. About a half-mile in my sphincter threw in the towel and I shit myself right there.
I almost cried. This is bad. Really bad. but it's mostly solid so nothing is running across the seats etc. Thankfully the luggage is still in the car so I have a change of clothes. I tried to find a truck stop thinking i could duck in and take a shower damn the strangers that see the shit stain in my shorts. No luck on the map app. Dial up a rest area and start heading that way.
Then the cramps start in again. fuck fuck fuck this one feels a bit looser. At this point I'm driving through a state park area with little to no traffic and trail heads every once in a while.
I pull into a trail head that has a long drive way. Get out of the car, grab a change of briefs and shorts dig through the car to find the baby wipes (there's only 6 in the can...). I start making my way into the woods keeping an ear out for cars. About 10 yards from the car the shit train gets going again and i hoof it off the edge of the trail, get my shorts and briefs off, but not before shitting myself a bit more and I'm able to squat and get the bulk of it on the ground and not on me. My ass, the back of my knee, and my inner thighs are a mess.
Thankfully I managed to get far enough into the woods that I can't be seen from the road but if anyone should pull into the trail head I'm probably fucked and, i realize, will likely have to, on top of everything else, register as a sex offender....
I chuck my pants and soiled briefs away from me and start trying to clean up with 6 or 7 wet wipes. I'm able to get the shit off me but obviously not the stink. I put on clean briefs and shorts and bag up my dirty laundry in a grocery bag stuffed under the seat (kept there to curb the dog...)
So I still can't really go back as I smell like shit and i'm not really clean. Also I still need to shit. Notice I managed to get shit on my shoe and my belt as well.
Log onto hotels.com and find a place 10 minutes away that's 80 a night. Fine. book the room. This place is a total shithole. Like sign on the office "bang on door of room 103 to check in". The mirror in the room is leaning against the wall. Smoke detector is hanging from wires. But, doesn't really matter I just want to shower. On the way there stopped by a gas station and left a most unpleasant suprise in the bin for the poor bastard that has to empty the trans bins...
I get showered when the phone rings. Wife wants to know where I am. Told her I decided to go for a walk in the state park nearby since I had been in a foul mood earlier (which was true) and thought the fresh air and alone time would be good. She asked if i'd be back soon. Told her probably within the hour.
Thankfully I had one pair of shorts that looked similar to the shitty ones. If not i was prepared to further my lie and say I took a swim and come back in swim trunks.
Now the briefs and shorts I was wearing for the ride from the woods to the shower also stank of shit. Shorts not so bad. Briefs, tossed in the trash at the Truck stop which, to my aggravation, turned out to be literally next door to the motel. Could have saved myself 90$. But fine whatever.
At the truck stop I picked up a new pack of wet wipes. Cleaned off my belt as best I could, and the seat of the car. The car seat didn't have any shit on it really as the in-car shit was more solid than juicy. But it still had the essence of shit. About 3 wipes took care of that.
I washed my hands many more times. I could still smell the faintest odor of shit on me though. But it was as good as I was going to get. made it back to the party 1 pair of shorts and 2 pair of briefs lighter, I also missed dinner in the two hours i was out "getting ice".
The resident canine party goers did their best to give me away and couldn't get enough of sniffing me. They knew what had happened and had a look in their eyes of "it's a good thing for you we can't talk pal!".
But my lie about taking a walk in the state park, which was kinda true..., was bought in full and I got myself into a 2nd shower ASAP.
Lesson learned, next time I'll not let my anxiety get the better of me and will have no issues stinking up the house and owning it. strangers or not.
Once or twice each day of the 3 day stay I contemplated how weird it would have been had I not been able to find a way to hide my fuck-up from my new friends.... or how much easier it would have been to just use the fucking toilet and open a window.....
Given my initial fuckup I'm pretty glad I was able to get out with a $90 hotel bill, and $30 in clothes. I figure it'll be a few years before I tell the wife. But I have to tell her eventually, on the condition that she tells no one that was there. It's to funny not to.
TL;DR: Grown ass man leaves party to take a shit. Shits himself on the drive. Finds a state park trail head to kinda clean himself up at. Books a $90 hotel room for a shower, misses dinner and throws away $30 worth of clothes. | 0non-cybersec
| Reddit | 1,565 | 6,379 |
How many cuts does it take to remove any $n$ vertices from an $m$-dimensional hypercube?. <p>For instance, in $m=3$ dimensions (cube), the following $n=3$ corners (red) can be cut off with a minimum of $C=2$ planes (blue). (Note you are only allowed to cut off the vertices in red.)</p>
<p><img src="https://i.stack.imgur.com/bshF7.png" alt="enter image description here"></p>
<p>So what about the general case of $n$ vertices on an $m$-dimensional hypercube? What is the minimum number of cuts $C(m,n)$ required to cut off any $n$ given vertices?</p>
| 0non-cybersec
| Stackexchange | 176 | 554 |
Read massive flat file into relational database. <p>I have a massive flat text file with ~4M records that I would like to read into MySQL using Ruby/Rails, Python, or any other method.</p>
<p>The flat file is roughly this format:
business_name,address,city,state,zip,employee_name</p>
<p>If there are multiple employees at the business, there will be one row for each employee with the business name, address, etc. repeated.</p>
<p>I'd like to read this in to two tables structured with the employees table having a foreign key like so:</p>
<pre><code>businesses (id int, name varchar, address varchar, city varchar, etc.)
employees (id int, name varchar, business_id int)
</code></pre>
<p>How do I go about efficiently reading this file in so that the employees/businesses are created and referenced as needed?</p>
<p>Note: it is NOT safe to assume that the file is sorted.</p>
<p>I've tried reading the file into SQL first and then using SQL to get a unique list of business_name/address/city/state combinations that I could then insert into the businesses table, but my server runs out of memory. And this is only with 1/4th of the records loaded.</p>
| 0non-cybersec
| Stackexchange | 311 | 1,162 |
Sudo Shutdown Now on Mavericks. <p>I had <a href="http://hints.macworld.com/article.php?story=20010406122933611" rel="nofollow">read</a> that you can "quietly shut down to single user mode" by running, within terminal:</p>
<pre><code>sudo shutdown now
</code></pre>
<p>This sounds far preferable to having to restart the computer and hold CMND+S. However - at least in Mavericks it doesn't seem to work.</p>
<p>I'm getting:</p>
<pre><code>shutdown: -h, -r, -s, or -k is required
usage: shutdown [-] [-h [-u] [-n] | -r [-n] | -s | -k] time [warning-message ...]
</code></pre>
<p>I thought that anything within square brackets was optional.</p>
<p>When I run it with the <code>-k</code> flag (which kicks all users off): <code>sudo shutdown -k now</code>, the output is:</p>
<pre><code>Shutdown NOW!
*** FINAL System shutdown message from user@computer_name ***
System going down IMMEDIATELY
System shutdown time has arrived
but you'll have to do it yourself
</code></pre>
<p>Then if I try to open a new terminal:</p>
<pre><code>NO LOGINS: System going down at 12:53
#my password
Login incorrect
login:
</code></pre>
<p>Restarting again and terminal login is restored.</p>
<p>Can anyone offer some insight as to what's going on here?</p>
| 0non-cybersec
| Stackexchange | 421 | 1,347 |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange | 349 | 1,234 |
Balancing for Concentrating on Two Spells. My party will soon be gaining access to a list of magical enhancements for the quest they are on. One of my reward options would be the following boon:
Focused Mind: When you cast a spell and are already concentrating on a spell or effect, you may concentrate on both spells or effects until the end of your next turn: at this time you may choose which effect to end concentration on. Each time you use this ability after the first time you use it per short rest you gain a point of exhaustion. If you were to cast a third concentration spell before one of your concentration spells ends you lose concentration on the earliest spell cast. If you were to fail a concentration check you lose concentration on both spells.
I was wondering if this is an effective balance for the potential abuse of concentrating on 2 spells at once. Am I being too harsh with the negative rider or too lenient?
I was also thinking about this alternative negative rider to replace the exhaustion points: Each time you use this ability after the first time you use it per short rest you take 1d8 psychic damage for each level of the spell you cast. This damage ignores resistance and immunity.
Any advice is welcome! Thank you! | 0non-cybersec
| Reddit | 265 | 1,265 |
What do each of the colors of files/folders returned from running the ls command mean in gnome terminal?. <blockquote>
<p><strong>Possible Duplicate:</strong><br>
<a href="https://askubuntu.com/questions/17299/color-meanings-in-terminal">Color Meanings in Terminal</a> </p>
</blockquote>
<p>When I run the</p>
<pre><code># ls
</code></pre>
<p>command, a list of files and folders are returned.</p>
<p>Some of them are colored blue, others green.</p>
<p>I'm new to terminal and just wanted to know if there were other colors and what each color says about the file or folder.</p>
| 0non-cybersec
| Stackexchange | 184 | 591 |
C++ pointer to member of derived class. <p>I don't understand what's happening here. I have a class <code>Base</code> that contains a field <code>a</code>. Now I create a <code>Derived</code> class that extend Base. I also have a template function that prints the field we want by passing a pointer-to-member template argument. </p>
<pre class="lang-cpp prettyprint-override"><code>#include <iostream>
class Base {
public:
Base(double a):a{a} {}
double a;
};
class Derived : public Base {
public:
Derived(double a) : Base(a) {}
};
template<double (Derived::*p)>
void print(Derived d) {
std::cout << d.*p;
}
int main() {
Derived d {10.0};
print<&Derived::a>(d);
}
</code></pre>
<p>The problem is that it doesn't work, but if I only use the base class:</p>
<pre class="lang-cpp prettyprint-override"><code>template<double (Base::*p)>
void print(Base b) {
std::cout << b.*p;
}
int main() {
Base b {10.0};
print<&Base::a>(b);
}
</code></pre>
<p>It works as expected and prints <code>10.0</code>. How can I get it to work with the subclass?</p>
<p>The compiler says:</p>
<pre><code>test.cpp:15:6: note: template argument deduction/substitution failed:
test.cpp:21:23: error: could not convert template argument ‘&Base::a’ from ‘double Base::*’ to ‘double Derived::*’
print<&Derived::a>(d);
</code></pre>
| 0non-cybersec
| Stackexchange | 498 | 1,397 |
What kind of QoS do I need?. <p>I have a small office. There are ~5 PCs connected via cable. There is 1 PC via WiFi, 3 VoIP phones and a bunch of cellphones connected via WiFi.</p>
<p>There is a Gigalan switch and a internet connection via a modem and router. The internet connection is 10 MB for download and 1MB for upload.</p>
<p>When an user is download a big file from the internet, all the others users cannot browse or cannot place calls. Or the calls have a big latency that makes them very low quality.</p>
<p>How do I diagnose where is the problem? A better switch would make things better? Or is it a problem with my router?</p>
<p>I can run a few tests using a linux box and come back with the results.</p>
<p><strong>UPDATE:</strong></p>
<p>My hardware configuration (all home equipment, nothing fancy):</p>
<ul>
<li>1 gigalan switch</li>
<li>1 cable modem (provided by my carrier)</li>
<li>1 linksys router with public ip</li>
<li>1 wifi access point (professional) connected to the switch.</li>
<li>3 voip phones directly connected to the switch (no wifi here). each one to different ports on the switch.</li>
<li>~5 PCs via ethernet and 1 via wifi.</li>
<li>I haven't set up any qos in the router or specific configuration.</li>
</ul>
| 0non-cybersec
| Stackexchange | 358 | 1,258 |
Angular 2 injector hierarchy and NgModule. <p>I wonder how <code>NgModule</code> actually affects Angular 2 injector hierarchy.</p>
<p>What does the hierarchy look like in an app with nested modules? Does it create a new injector instance per each module or gets access to top-level injector (similarly to Angular 1.x modules)?</p>
<p>It can be somewhat confusing to figure out the tree in a big app.</p>
<p>Is there a way to print out, inspect or explore visually the hierarchy of injectors (like it could be done for scope hierarchy in Angular 1.x)?</p>
| 0non-cybersec
| Stackexchange | 151 | 559 |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange | 349 | 1,234 |
Combine the effects of separate delete and insert rows.
<p>How to I combine the two rows below:</p>
<pre><code>Date Id For_Id Type New_Value Old_Value
------------------------------------------------------------------
2015-08-13 6 327 DELETE NULL Value1
2015-08-13 6 327 INSERT Value2 NULL
</code></pre>
<p>...into a single row, removing the <code>NULLs</code>, matching rows based on the dates?</p>
<pre><code>Date Id For_Id New_Value Old_Value
-------------------------------------------------
2015-08-13 6 327 Value2 Value1
</code></pre>
| 0non-cybersec
| Stackexchange | 176 | 653 |
Socket connection into Docker initially succeeds then fails. <p>Running under MacOS I am connecting from a node.js app with net.Socket() into a Docker container running on the same host, which contains a C++ sockets server under Centos. The Docker run command is:</p>
<pre><code>docker run -it --rm -p 14000-14010:14000-14010 -v /Users/me/Development/spdz:/spdz spdz/spdzdev
</code></pre>
<p>When the c++ server in docker is <strong>not</strong> running, I see a successful connection in node followed 3ms later by a socket closed message.</p>
<p>It appears as if a proxy in front of the container is accepting the request, passing it through to Docker where it is rejected. However this leads to erroneous messages in my front end application which thinks the connection was successful, only to find out later it was not.</p>
<p>I would like to see a simple connection declined. Any suggestions as to how this may be remedied or better understood would be helpful. </p>
<p>I am confident that the behaviour is introduced by Docker, as running the components outside Docker gives the expected immediate failure on connection. Also I have tried mapping the exported ports to an external network interface rather than localhost but see the same behaviour.</p>
| 0non-cybersec
| Stackexchange | 304 | 1,263 |
`xmodmap` not working on startup. <p>I recently installed Debian 9 and inserted my usual <code>~/.Xmodmap</code> file and added <code>xmodmap ~/.Xmodmap</code> to my <code>.xsession</code>. To my disappointment this didn't actually work. </p>
<p>For reference, I run <code>i3</code> from <code>startx</code> without a DM.</p>
<p>To test if the command ran successfully I replaced the command in my <code>.xsession</code> with <code>touch ~/prior && xmodmap ~/.Xmodmap && touch ~/post</code>. And the files were in fact created indicating that the <code>xmodmap</code> command was indeed ran correctly but the mappings were reset somewhere, probably by a call to <code>setxkbmap</code>. </p>
<p>I searched for a solution and found only questions without answers, or questions with old answers that didn't work for me, or that contained no real solution:</p>
<ul>
<li><a href="https://askubuntu.com/questions/7190/why-wont-my-xmodmap-file-load-on-login">Why won't my ~/.Xmodmap file load on login?</a> </li>
<li><a href="https://unix.stackexchange.com/questions/1677/why-wont-my-xmodmap-command-run-on-startup-login">Why won't my xmodmap command run on startup/login?</a></li>
<li><a href="https://askubuntu.com/questions/54157/how-do-i-set-xmodmap-on-login">How do I set Xmodmap on login?</a></li>
<li><a href="https://unix.stackexchange.com/questions/43672/openbox-overwrites-xmodmap-configuration?rq=1">Openbox overwrites xmodmap configuration</a></li>
</ul>
| 0non-cybersec
| Stackexchange | 493 | 1,480 |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange | 349 | 1,234 |
n-bucket water puzzle. <p>Inspired by this <a href="https://math.stackexchange.com/questions/324594/three-bucket-water-puzzle">post</a>. I am thinking of a general case.</p>
<p><a href="https://mathoverflow.net/questions/5800/generalization-of-the-two-bucket-puzzle">Reference</a> to read.</p>
<p>Suppose $N,L_1,L_2,p,q$ are integers, and $N L_1 = pq$. with $p\ge 2$ and $L_1>L_2$.</p>
<p>Now you have $N+1$ buckets, the first $N$ buckets are full of water, each of these buckets can hold $L_1$ liters of water, the left one is a small bucket which is empty at first, the small bucket can hold $L_2$ liters of water.</p>
<p>Now the problem is I want to split the $N L_1$ liters of water to $p$ people evenly, everybody can get $q$ liters of water.</p>
<p><strong>Question: in what situation $(L_1,L_2,N,p,q)$ we can split the water evenly, in what case we cannot.</strong></p>
<hr>
<p>For $p=1$ case, that means all the water will go to one people, that is easy.</p>
<p>For the original problem setting, if we change the capacity of the small bucket, let $(L_1,L_2,N,p,q)=(8,L_2,2,4,4)$, we can see that </p>
<ol>
<li>when $L_2 = 1$, it is easy to do, we just get $1$ liter of water every time.</li>
<li>when $L_2 = 2$, it also easy, we just get $2$ liters of water every time.</li>
<li>$L_2 =3$ is done in the post.</li>
<li>$L_2=4$ is also easy as the first two.</li>
<li>I can prove when $L_2 = 6,7$, we cannot succeed.</li>
</ol>
<p>I guess, if $L_2>q$, then we cannot succeed. I am trying to cook up a theory on this, but very limited. Since to find out a proper way to split is kind of NP hard.</p>
<p><strong>Conjecture 1</strong>:
$gcd(L_1,L_2)\mid q$ and $L_2\le q$ are necessary(not sufficient) to find a solution.</p>
| 0non-cybersec
| Stackexchange | 654 | 1,748 |
custom key sequence in ubuntu mate. <p>I've been looking at custom key shortcuts on Ubuntu, but I haven't seen anything regarding custom key sequence in Ubuntu Mate 16.04.1.LTS:
Ideally, when I press:</p>
<p><em>the windows key + enter,</em> </p>
<p>this would trigger, in sequence:</p>
<p><em>alt+right, control-v, alt-left</em></p>
<p>Is this possible? If it's then possible to tweak the timing between these 3 combos, that'd be amazing, but likely unnecessary. I don't know how lofty my dreams can be in Ubuntu Mate...</p>
| 0non-cybersec
| Stackexchange | 165 | 531 |
Frequent crashing on BrettSpielWelt? Solution inside.... I was playing Dominion on BSW (www.brettspielwelt.de) with some friends last night and some of the players were having the game lock up on them every few minutes. You can re-join the game just by restarting the client so it's not a HUGE disaster, but it certainly slowed the game down a lot. Sometimes it would crash twice in the same player's turn!
Anyway, I did some digging afterward to see if there's a fix. Apparently the issue is caused by the JVM running out of memory from all the pretty high-resolution graphics, and due to the sandboxed-ness of Java it can't easily request more after the app has been launched. Resizing the window to make it bigger than the default exacerbates the issue, since a bigger window means more pixels means more memory taken up on graphics. You could just leave the window at the default size, but that's no fun, so here's
-----
**THE FIX**
* First, if you haven't already, download the standalone client. It's exactly the as the web-based client, but it installs on your computer so you don't have to load the .jar file from BSW every time. Downloads are [here](http://www.brettspielwelt.de/Community/Download/).
* If you just installed the client, run it once so it can download all the game data.
* Next, create a shortcut. For the Target field, put:
"C:\Program Files\Java\jre6\bin\javaw.exe" -cp "." -Xms64m -Xmx256m de.brettspielwelt.client.Starter
The above assumes java is installed in "C:\Program Files\Java", so if you put it somewhere else, adjust accordingly.
* For Vista or Windows 7, change the Start in field to:
%APPDATA%\Roaming\BSW
On XP it's:
%APPDATA%\BSW
This is where the updater stores the actual program data.
-----
Basically what this shortcut does is sets the initial Java heap size to 64MB (-Xms64m) and the maximum Java heap size to 256MB (-Xmx256m). You can increase it further, to say -Xmx512m if you still get crashes, though it's more likely that something else besides running out of memory is causing them at that point. Without these options, the default maximum heap size is 64MB, which is downright puny by modern standards, and you can see how that could cause problems.
Edit: The same fix should work for the OSX and Linux clients as well, just create a shell script using this template:
`cd` *path\_to\_installed\_app\_data*
`java -cp . -Xms64m -Xmx256m de.brettspielwelt.client.Starter` | 0non-cybersec
| Reddit | 669 | 2,453 |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange | 349 | 1,234 |
Proof by induction step $k(k+1)+2(k+1)=(k+1)(k+2)$. <p>I think I do understand the proof by induction right now but on the tutorial I am watching, I don't understand the last steep.</p>
<p>How is it possible to go from <span class="math-container">$k(k+1)+2(k+1)$</span> to <span class="math-container">$(k+1)(k+2)$</span>? </p>
<p>thank you</p>
<p><a href="https://i.stack.imgur.com/L21CV.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/L21CV.png" alt="Video"></a></p>
| 0non-cybersec
| Stackexchange | 192 | 492 |
HDD activity when computer is idle. <p>What can cause HDD activity when computer is left idle? My HDD is quite loud and I want to get rid of the noise when computer is idle.</p>
<p>It happens on Windows 7, automatic defragmentation and antivirus background scanning are turned off. Recently noticed it happen also while running Windows 10 TP install (which is installed on another drive - SSD, but the activity is still on HDD). I've looked into Resource manager - "Processes with Disk Activity" and found only system processes there, <strong>svchost.exe</strong> mainly - does it mean, it's some service causing this HDD activity? How do I found out which one?</p>
<p>UPDATE:</p>
<p>Based on PID I've found out which svchost process is causing it. <img src="https://i.stack.imgur.com/4kXLz.png" alt="enter image description here"></p>
| 0non-cybersec
| Stackexchange | 223 | 839 |
Beamer/TikZ shadow printed via Adobe Reader (PostScript) cause errors. <p>Consider the example below compiled using <code>pdflatex</code>. Basically it is a simple test of the Frankfurt theme and the Whale color theme (just attempting to make something smaller).</p>
<p>We experience problems with this example when printed on our Konica Minolta C360.</p>
<p>When we print from Adobe Reader, on Linux (or Mac, or from Windows using a PostScript Driver), the print is ignored. Prints fine if printed on Canon, HP or Oki, also print fine if we do not use Adobe Reader!</p>
<p>AR also prints on the KM, if the file is made using <code>latex+dvips+ps2pdf</code>.</p>
<p>I'm having some discussions with KM as to what the problem is.</p>
<p>Here are a few interesting observations.</p>
<p>If I print the PDF to a PS file on Linux using AR 8, the Adobe Distiller 9 on Win7, complain and recreate a PDF that is flawed.</p>
<p>AR X on Win 7, freezes if I attempt to print the PDF to a file.</p>
<p>The main problem in the PDF is the shadow, there is no problem if I remove the shadow.</p>
<p>Does anyone know if there are Adobe problems in regards to some of the shadings used by TikZ? (when compiling with <code>pdflatex</code>)</p>
<p>I can provide some of the generated files if needed.</p>
<p>I use an up to date TL 11 system to create the offending PDF.</p>
<p>Any comments?</p>
<pre><code>\documentclass[handout]{beamer}
\usepackage{tikz}
%\usetheme{Frankfurt}
\makeatletter
\def\beamer@themerounded@shadow{true}
%\def\beamer@themerounded@shadow{false}
\setbeamertemplate{title page}[default][colsep=-4bp,rounded=true,shadow=\beamer@themerounded@shadow]
\usecolortheme{whale}
\title{Test}
\author{}
\date{}
\begin{document}
\begin{frame}
\titlepage
\end{frame}
\end{document}
</code></pre>
| 0non-cybersec
| Stackexchange | 573 | 1,803 |
INNER JOIN select columns from table2. <p>How can I select certain columns from the second and third tables using <strong>INNER JOIN</strong></p>
<pre><code>SELECT
*
FROM
1_packages_plu AS p
INNER JOIN
1_stock as s ON p.fk_products_id = s.fk_products_id
AND branch = 1
INNER JOIN
1_products AS j ON p.fk_products_id = j.id
WHERE
fk_packages_id = 54;
</code></pre>
<p>In the tables <code>1_stock</code> I only want to return the value of <code>stock-repair</code> columns and in the <code>1_products</code> all I need is make,model columns</p>
| 0non-cybersec
| Stackexchange | 201 | 590 |
How to check an AUR package for malicious code?. <p>Malicious code has been found and deleted later from 3 AUR packages <code>acroread</code>, <code>blaz</code> and <code>minergate</code> (<a href="https://aur.archlinux.org/cgit/aur.git/commit/?h=acroread&id=b3fec9f2f16703c2dae9e793f75ad6e0d98509bc" rel="nofollow noreferrer">e,g: acroread PKGBUILD detail</a>). It was found in a commit released by a malicious user by changing the owner of the orphaned AUR package and including a malicious <code>curl</code> command.</p>
<p>The <code>curl</code> command will download the main bash script <code>x</code> then the second script <code>u</code> (<code>u.sh</code>) in order to create a systemd service and using a function to collect some system data (non sensitive data) but the scripts can be modified by the attacker to be uploaded sequentially.</p>
<p>In practice not all users have the ability to check the PKGBUILD before building any package on their systems for some reasons (require some knowledge , take more time etc...). To understand how it work I have downloaded and uploaded the 2 bash scripts on <a href="https://pastebin.com/5xqU9LC7" rel="nofollow noreferrer">this pastbin page</a>.</p>
<p>What is the easiest way to check an AUR package for malicious code? </p>
<p><a href="https://nakedsecurity.sophos.com/2018/07/11/another-linux-distro-poisoned-with-malware/" rel="nofollow noreferrer">naked security : Another Linux community with malware woes</a></p>
<p><a href="https://thehackernews.com/2018/07/arch-linux-aur-malware.html" rel="nofollow noreferrer">Malicious Software Packages Found On Arch Linux User Repository</a></p>
| 1cybersec
| Stackexchange | 510 | 1,657 |
How to consume soap service in react native?. <p>I am new in react native and wanted to consume soap service but did not get any api to do that. I have used fetch api for Rest service with json parser. Is there any api available to consume soap service and parse xml in react-native. In ios we create soap envelope and send to the server like :</p>
<pre><code>NSString *soapMessage = [NSString stringWithFormat:
@"<?xml version=\"1.0\" encoding=\"utf-8\"?>\n"
"<soap:Envelope xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchem\" xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\">\n"
"<soap:Body>\n"
"<GetCitiesByCountry xmlns=\"http://www.webserviceX.NET\">\n"
"<CountryName>%@</CountryName>\n"
"</GetCitiesByCountry>\n"
"</soap:Body>\n"
"</soap:Envelope>\n",@"India"];
NSURL *url = [NSURL URLWithString:@"http://webservicex.com/globalweather.asmx"];
NSMutableURLRequest *theRequest = [NSMutableURLRequest requestWithURL:url];
[theRequest addValue: @"http://www.webserviceX.NET/GetCitiesByCountry"
forHTTPHeaderField:@"SOAPAction"];
[theRequest addValue: [NSString stringWithFormat:@"%lu",(unsigned long)[soapMessage length]]
forHTTPHeaderField:@"Content-Length"];
[theRequest setHTTPMethod:@"POST"];
[theRequest addValue: @"text/xml; charset=utf-8" forHTTPHeaderField:@"Content-Type"];
[theRequest setHTTPBody: [soapMessage dataUsingEncoding:NSUTF8StringEncoding]];
self.responseData = [[NSMutableData alloc]init];
NSURLSession *soapSession = [NSURLSession sessionWithConfiguration:[NSURLSessionConfiguration defaultSessionConfiguration] delegate:self delegateQueue:[NSOperationQueue mainQueue]];
NSURLSessionDataTask *dataTask = [soapSession dataTaskWithRequest:theRequest];
[dataTask resume];
</code></pre>
<p>Same thing I am looking in react-native.</p>
| 0non-cybersec
| Stackexchange | 601 | 2,082 |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange | 349 | 1,234 |
nginx / ssl: Always redirect to one of two https subdomains. <p>My webserver supports the following two subdomains:</p>
<ul>
<li><a href="https://www.example.com" rel="nofollow noreferrer">https://www.example.com</a></li>
<li><a href="https://en.example.com" rel="nofollow noreferrer">https://en.example.com</a></li>
</ul>
<p>I want to create my nginx config so that:</p>
<ol>
<li><a href="http://en.example.com" rel="nofollow noreferrer">http://en.example.com</a>$request_uri => <a href="https://en.example.com" rel="nofollow noreferrer">https://en.example.com</a>$request_uri</li>
<li><a href="http://www.example.com" rel="nofollow noreferrer">http://www.example.com</a>$request_uri => <a href="https://www.example.com" rel="nofollow noreferrer">https://www.example.com</a>$request_uri</li>
<li>Every other subdomain independent of http or https => <a href="https://www.example.com" rel="nofollow noreferrer">https://www.example.com</a>$request_uri</li>
</ol>
<p>I could not find any solution online that solves this problem. Can anybody help me out with the correct nginx config.</p>
| 0non-cybersec
| Stackexchange | 381 | 1,091 |
How to power down display on terminal?. <p>I would like to power down/up my display from the terminal.</p>
<p>Right now I have:</p>
<pre><code>setterm --blank force
#wake
setterm --blank poke
</code></pre>
<p>Which gives a blank screen; but active screen (screen still receives output from computer, just blank output, it won't enter a "no signal" state)</p>
<p>How would I turn off the display completely like you can do from X with this?</p>
<pre><code>xset dpms force off
#wake
xset dpms force on
</code></pre>
| 0non-cybersec
| Stackexchange | 165 | 519 |
What's the difference between the "remainder" and "radius of convergence" for Taylor series that converge for all $x$?. <p>From what I can understand, the remainder is how much difference there is between the function itself and the polynomial approximation. And the radius of convergence is related to the series representation of the polynomial approximation, and how its convergence could be tested by the ratio test.</p>
<p>But what's the difference between them when they seem to tell you the same thing?</p>
<p>For example, since <span class="math-container">$\sin(x)$</span> is <span class="math-container">$$ \sum_{n=0}^\infty(-1)^n \frac{x^{2n+1}}{(2n+1)!}, $$</span> it seems that we can find that it converges for all values of <span class="math-container">$x$</span> by either</p>
<ol>
<li>making to the remainder becomes zero (by having it approach <span class="math-container">$0$</span> by having <span class="math-container">$n$</span> approach <span class="math-container">$\infty$</span>.</li>
<li>showing that the ratio test has convergence criteria</li>
</ol>
<p>My other example would be <span class="math-container">$e^x$</span>, but that seems easier to do the ratio test on since the <span class="math-container">$f^{(n+1)}(c)$</span> term isn't bounded.</p>
<p>It seems that doing the ratio test for <span class="math-container">$\sin(x)$</span> will give me the same result as making the remainder <span class="math-container">$0$</span>, and finding that the remainder is <span class="math-container">$0$</span> for <span class="math-container">$e^x$</span> is the same result as the ratio test.</p>
| 0non-cybersec
| Stackexchange | 471 | 1,651 |
Collecting package metadata (current_repodata.json): failed NotWritableError: The current user does not have write permissions to a required path. <p>When i am trying to install any library such as pandas and even when i tried to install clean package using <code>conda install anaconda-clean</code>.
it gives an error :</p>
<pre><code>Collecting package metadata (current_repodata.json): failed
NotWritableError: The current user does not have write permissions to a required path.
path: /home/parth/.conda/pkgs/urls.txt
uid: 1000
gid: 1000
If you feel that permissions on this path are set incorrectly, you can manually
change them by executing
$ sudo chown 1000:1000 /home/parth/.conda/pkgs/urls.txt
In general, it's not advisable to use 'sudo conda'.
</code></pre>
| 0non-cybersec
| Stackexchange | 223 | 782 |
Best event based architecture for Linux to GUI. <p>I've looked around <a href="https://www.quora.com/What-are-the-most-popular-online-forums-or-chatrooms-for-software-engineers-to-discuss-programming-practices-and-methodologies" rel="nofollow noreferrer">a</a> <a href="https://meta.stackoverflow.com/questions/252777/is-there-a-less-restrictive-stack-exchange-site-specially-suited-for-not-too-spe">bit</a> and probably haven't found the right medium for this question so let me know if there's a different forum I should bother. </p>
<p>First, there is an application managed by another group that does some simulations and communicates to our system via Ethernet. Let's call this App.</p>
<p>Now, we have the following setup on a Red Hat Enterprise Linux system: </p>
<ol>
<li>Legacy Ada code (used to communicate with App following a predefined
standard)</li>
<li>Linux csh/sh scripts (call Ada tasks to communicate with App or
write files to update Flash - either called by Ada tasks or
constantly running alongside program to monitor status)</li>
<li>Actionscript 2 Flash Movie in Firefox window (GUI - polls files to
see if updates are necessary and loads variables to PHP to make
system calls, call Linux scripts, or run Ada tasks)</li>
<li>PHP (used by Flash to call Linux scripts and Ada tasks to
communicate with App)</li>
</ol>
<p>I am looking for architectural improvements. Obviously the mishmash of languages is a nightmare. Above that, Flash is difficult to work with because we haven't been able to get an interrupt-driven architecture in place. I've tried to use Flash's ExternalInterface class for a more event-based flow, but whoever setup the Flash environment did so in a way that there is no available ExternalInterface. "Finally" (for this post), our program is run on a local machine, so running a .swf in a Firefox window is unnecessary. </p>
<hr>
<p>Thanks for the feedback! Let me respond to the first three comments I see: </p>
<ol>
<li>It would be an absolute dream to get time and money to rewrite the
entire system in a more coherent manner. I expect significant resistance
(because I've already tried a few times), but I will do more
research and attempt to gather more compelling cases and
communicate the "feebleness" of only updating part of the
"design". </li>
<li>You're right - I was rushing too much to think it was necessary to
know the guts. Basically I was hoping for stuff like, "My favorite
languages/tools/patterns/paradigms/etc for an architecture that
needs to have a GUI and interact with Linux is blah" or "An
interrupt driven architecture for AS2 does exist, it's blah" or
"ExternalInterface isn't available? Have you made sure that blah?".
I've updated the above with maybe more useful information. Let me
know if that didn't actually clarify anything.</li>
<li>Hopefully the previous response helps explain what the pieces do to
some degree.</li>
</ol>
<p>EDIT: I no longer work on this project, but we can keep the thread open if anyone else thinks it'll be useful for others (doubtful as I hope no one ever runs into this embarrassing situation). What ended up happening was <code><whine></code> despite repeated attempts from me and two other developers to suggest rewriting the entire application in Java/Python, we never convinced anyone. Then another developer (not on the project) volunteered to rewrite everything in Java and everyone jumped on board all of a sudden so now the whole thing is in Java (not App, but everything in 3 and 4 is now Java). <code></whine></code></p>
| 0non-cybersec
| Stackexchange | 917 | 3,563 |
Generate all permutations of a list without adjacent equal elements. <p>When we sort a list, like</p>
<pre><code>a = [1,2,3,3,2,2,1]
sorted(a) => [1, 1, 2, 2, 2, 3, 3]
</code></pre>
<p>equal elements are always adjacent in the resulting list. </p>
<p>How can I achieve the opposite task - shuffle the list so that equal elements are never (or as seldom as possible) adjacent?</p>
<p>For example, for the above list one of the possible solutions is</p>
<pre><code>p = [1,3,2,3,2,1,2]
</code></pre>
<p>More formally, given a list <code>a</code>, generate a permutation <code>p</code> of it that minimizes the number of pairs <code>p[i]==p[i+1]</code>. </p>
<p>Since the lists are large, generating and filtering all permutations is not an option.</p>
<p>Bonus question: how to generate all such permutations efficiently?</p>
<p>This is the code I'm using to test the solutions: <a href="https://gist.github.com/gebrkn/9f550094b3d24a35aebd" rel="nofollow noreferrer">https://gist.github.com/gebrkn/9f550094b3d24a35aebd</a></p>
<p>UPD: Choosing a winner here was a tough choice, because many people posted excellent answers. <a href="https://stackoverflow.com/a/25285879/989121">@VincentvanderWeele</a>, <a href="https://stackoverflow.com/a/25290780/989121">@David Eisenstat</a>, <a href="https://stackoverflow.com/a/25291640/989121">@Coady</a>, <a href="https://stackoverflow.com/a/25286137/989121">@enrico.bacis</a> and <a href="https://stackoverflow.com/a/25401193/989121">@srgerg</a> provided functions that generate the best possible permutation flawlessly. <a href="https://stackoverflow.com/a/25286251/989121">@tobias_k</a> and David also answered the bonus question (generate all permutations). Additional points to David for the correctness proof.</p>
<p>The code from @VincentvanderWeele appears to be the fastest.</p>
| 0non-cybersec
| Stackexchange | 631 | 1,839 |
How to apply stopwords accurately in French using R. <p>I'm trying to pull a book using the Gutenberg library and then remove French stopwords. I've been able to do this accurately in English by doing this:</p>
<pre><code>twistEN <- gutenberg_download(730)
twistEN <- twistEN[118:nrow(twistEN),]
twistEN <- twistEN %>%
unnest_tokens(word, text)
data(stop_words)
twistEN <- twistEN %>%
anti_join(stop_words)
countsEN <- twistEN %>%
count(word, sort=TRUE)
top.en <- countsEN[1:20,]
</code></pre>
<p>I can see here that the top 20 words (by frequency) in the English version of Oliver Twist are these:</p>
<pre><code>word n
<chr> <int>
1 oliver 746
2 replied 464
3 bumble 364
4 sikes 344
5 time 329
6 gentleman 309
7 jew 294
8 boy 291
9 fagin 291
10 dear 277
11 door 238
12 head 226
13 girl 223
14 night 218
15 sir 210
16 lady 209
17 hand 205
18 eyes 204
19 rose 201
20 cried 182
</code></pre>
<p>I'm trying to accomplish the same thing with the French version of the same novel:</p>
<pre><code>twistFR <- gutenberg_download(16023)
twistFR <- twistFR[123:nrow(twistFR),]
twistFR <- twistFR %>%
unnest_tokens(word, text)
stop_french <- data.frame(word = stopwords::stopwords("fr"), stringsAsFactors = FALSE)
stop_french <- get_stopwords("fr","snowball")
as.data.frame(stop_french)
twistFR <- twistFR %>%
anti_join(stop_words, by = c('word')) %>%
anti_join(stop_french, by = c("word"))
countsFR <- twistFR %>%
count(word, sort=TRUE)
top.fr <- countsFR[1:20,]
</code></pre>
<p>I did alter the code for the French stopwords based on info I found online, and it is removing some stopwords. But this is the list I'm getting:</p>
<pre><code>word n
<chr> <int>
1 dit 1375
2 r 1311
3 tait 1069
4 re 898
5 e 860
6 qu'il 810
7 plus 780
8 a 735
9 olivier 689
10 si 673
11 bien 656
12 tout 635
13 tre 544
14 d'un 533
15 comme 519
16 c'est 494
17 pr 481
18 pondit 472
19 juif 450
20 monsieur 424
</code></pre>
<p>At least half of these words should be getting captured by a stopwords list and they're not. Is there something I'm doing wrong in my code? I'm new to tidy text, so I'm sure there are better ways to get at this.</p>
| 0non-cybersec
| Stackexchange | 873 | 2,518 |
Updating a mutable named set in nftables with responses from bind. <p>I need to apply an <code>nftables</code> rule to all traffic originating from a specific host, but the packets will not necessarily include the proper FQDN, so I need to rely on the IP address(s). The issue is that there are multiple redundant IP's returned for the FQDN that may change order/priority from time to time, or may even be replace entirely. </p>
<p>Because there are multiple IP's returned, I have to use a mutable named <code>set</code>, but I need that set to update somewhat regularly to ensure we have an up to date list of IP's to match against.</p>
<p>We have BIND9 (<code>named</code>) on the server so my thought is that I could have a cron job script that:</p>
<ol>
<li>Flush the local dns resolver for the the FQDN with <code>rdnc flushname...</code>, </li>
<li>Then dig against it to update the resolver cache with <code>dig +short...</code>, </li>
<li>Run <code>nft add element...</code> with the new ones,</li>
<li>Flush the old named set with <code>nft delete element...</code></li>
</ol>
<p>Is this the right way to go about this, or have I overthought something thats already been solved another way?</p>
| 0non-cybersec
| Stackexchange | 350 | 1,210 |
Not able to access file via SMB but able to access from NTFS. <p>I have a strange problem.</p>
<p>I have a file uploaded by some colleague via mapped drive. She is able to read the file after uploading. She has write/read/execute/list NTFS permission, and I see she is the owner of files.</p>
<p>Then some other colleague tell me she can't read these files via mapped drive, they have the same NTFS permission and sharing permission.</p>
<p>Then I test by myself, directly on the server:
1. I can't read either from mapped drive, and I logged as admin user
2. I can read it, via NTFS physical drive.
3. All sharing is inherited from the sharing root.</p>
<p>From ACL checking everything is correct. Other folders/files from the same sharing root is ok.</p>
<p>Do you have any ideas?</p>
| 0non-cybersec
| Stackexchange | 217 | 792 |
Running PowerShell cmdlets in C#. <p>I need to run powershell cmdlets using C# in Visual Studio Console.</p>
<pre><code>using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Management.Automation;
using System.Threading;
using System.Management.Automation.Runspaces;
using System.Collections.ObjectModel;
using System.Collections;
namespace ConsoleApp1
{
class Program
{
private static string RunScript()
{
Runspace runSpace = RunspaceFactory.CreateRunspace();
runSpace.Open();
Pipeline pipeline = runSpace.CreatePipeline();
Command cmd = new Command("Connect-MsolService");
pipeline.Commands.Add(cmd);
ICollection results = pipeline.Invoke(); // Here exception occurs
runSpace.Close();
StringBuilder stringBuilder = new StringBuilder();
foreach (PSObject obj in results)
{
stringBuilder.AppendLine(obj.ToString());
}
return stringBuilder.ToString();
}
static void Main(string[] args)
{
using (PowerShell PowerShellInstance = PowerShell.Create())
{
Console.WriteLine(RunScript());
Console.ReadKey();
}
}
}
}
</code></pre>
<p>When I run the code an Exception occurs:</p>
<blockquote>
<p>The term 'Connect-MsolService' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.</p>
</blockquote>
<p>Even though it works when I run the commands in Powershell.</p>
| 0non-cybersec
| Stackexchange | 444 | 1,773 |
I knew I was fat, when blind people knew I was fat. . Years ago I worked for for a state Deaf/Blind school, I am an ASL interpreter. I always knew I was chunky, big boned, hardy, whatever other terms I could use to describe my physical appearance without admitting I was obese. What bothered me more than my physical appearance, was knowing how unhealthy I was.
One day after walking up two flights of stairs to get to my office, a blind co-worker asked if I was alright. I was confused and responded "yes, why?" He told me he could hear me breathing heavy and was concerned. I had to confess that I was out of breath because walking up the stairs was difficult for me. He responded "oh, I didn't know you were overweight." I was crushed and thought that was incredibly insensitive of him.
I wanted to crawl in a hole and die. I was mortified, ashamed, embarrassed. He couldn't see that I no longer fit into my jeans, he couldn't see my discomfort in my office chair, he was oblivious to my physical appearance. He knew my body was failing me, or I was failing my body and he didn't even have to see me to know it.
That day everything changed. I got a gym membership that afternoon, asked my friends to support me and lost 100 pounds that year. I've kept it off for 5 years now and often think of the man who heard my fat. But, after I lost the weight, while I worked there I made it a point to make him hear me running up the stairs -- without panting or wheezing. Proving to us both that I was no longer out of shape.
Sometimes you need to hear the things you already know.
Tl;dr - I was so overweight that a blind person commented on my heavy breathing after walking two small flights of stairs that I changed my life and lost 100 pounds. Now I thank him every time I walk up stairs. | 0non-cybersec
| Reddit | 433 | 1,808 |
Script to run commands as soon as a key is hit. <p>I would like to make a repeating function in bash, that runs the same
three commands every time any key is pressed.</p>
<p>In Windows, I can do this by having the pause command in an infinite loop
in a batch file, which works fine for my needs.</p>
<p>Most *nix distros don't have a pause command equivalent, and <code>read
-p</code> is not functioning the way I would like.</p>
<p>What is the best way to accomplish what I need? Additionally, would it
be possible to have a different command (for cleanup) executed when a
certain key combination (say <kbd>Ctrl</kbd>-<kbd>C</kbd>) is input?</p>
| 0non-cybersec
| Stackexchange | 186 | 650 |
Docker Node Alpine Image Build Fails on node-gyp. <p>I'm attempting to Dockerize a Vue.js application. I'm using the <code>node:10.15-alpine</code> Docker image as a base. The image build fails with the following error:</p>
<pre><code>gyp ERR! configure error
gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.
gyp ERR! stack at PythonFinder.failNoPython (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:484:19)
gyp ERR! stack at PythonFinder.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:406:16)
gyp ERR! stack at F (/usr/local/lib/node_modules/npm/node_modules/which/which.js:68:16)
gyp ERR! stack at E (/usr/local/lib/node_modules/npm/node_modules/which/which.js:80:29)
gyp ERR! stack at /usr/local/lib/node_modules/npm/node_modules/which/which.js:89:16
gyp ERR! stack at /usr/local/lib/node_modules/npm/node_modules/isexe/index.js:42:5
gyp ERR! stack at /usr/local/lib/node_modules/npm/node_modules/isexe/mode.js:8:5
gyp ERR! stack at FSReqWrap.oncomplete (fs.js:154:21)
gyp ERR! System Linux 4.9.125-linuxkit
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /app/node_modules/inotify
gyp ERR! node -v v10.15.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
</code></pre>
<p>The application runs on my Ubuntu machine. And I've searched for a resolution online.</p>
<p>I tried:</p>
<pre><code>FROM node:10.15-alpine
EXPOSE 8080
RUN mkdir -p /app/src
WORKDIR /app
COPY build/ config/ dist/ static/ .babelrc .postcssrc.js index.html /app/
COPY package*.json ./
RUN apk add --no-cache make gcc g++ python && \
npm install --production --silent && \
apk del make gcc g++ python
ADD src/ /app/src/
CMD ["npm", "start"]
</code></pre>
<p>This fails too. The error output is quite verbose and references C/C++ code.</p>
<p>Here's my current Dockerfile:</p>
<pre><code>FROM node:10.15-alpine
EXPOSE 8080
RUN mkdir -p /app/src
WORKDIR /app
COPY build/ config/ dist/ static/ .babelrc .postcssrc.js index.html /app/
COPY package*.json ./
RUN npm install
ADD src/ /app/src/
CMD ["npm", "start"]
</code></pre>
<p>Can anyone help me to resolve this issue with node-gyp? I'd like to be able to run the application from with a Docker container, but I need to get the image to build first.</p>
<h3>Update</h3>
<p>Since the build was working on my Ubuntu machine, I checked the <code>node</code> version. It was 8.12, so I switch to using the <code>node:8.12-alpine</code> image and the application now works with the following Dockerfile:</p>
<pre><code>FROM node:8.12-alpine
RUN apk add g++ make python
EXPOSE 8080
RUN mkdir /app
WORKDIR /app
COPY . /app
RUN npm install
CMD ["npm", "start"]
</code></pre>
| 0non-cybersec
| Stackexchange | 1,202 | 3,379 |
Postgres: query on huge (11gb ) index does not return. <p>Using Postgres 9.6, I have created a table with 435M rows which is 120GB in size and have added an index which is 11GB in size.</p>
<p>I now want to iterate on the distinct values of the index, but the query fails with no error, it just does not complete. I can see no cpu usage or ram being used. Nb the server is on aws rds with 15GB of ram. </p>
<p>How to best troubleshoot this? Trying to iterate through it with <code>LIMIT</code> and <code>OFFSET</code> fails after about 3 cycles. I haven't managed to get a number of the unique values in the index. </p>
<p>I will try reindexing to see if there is indeed anything corrupted, but any suggestions on using a 11GB index would be great. </p>
<p>Editing to add more info:</p>
<p>This is the format of my table</p>
<pre><code>id bigint,
hit1 character varying(50),
hit2 character varying(50),
offset integer,
year character varying(50)
</code></pre>
<p>Row estimate is at 431M rows, approx size at 115GB according to postgres. </p>
<p>Index is on hit1 column with a size of 11GB. </p>
<p>I am trying to calculate the counts of hits:</p>
<pre><code>select hit1,hit2, count(distinct id) as total_count_of_ids,
count(case when offset=-1 then 1 else null end) as prev_position,
count(case when offset=0 then 1 else null end) as same_position,
count(case when offset=1 then 1 else null end) as next_position,
min(cast(substring(year,1,4) as int)) as min_year,
max(cast(substring(year,1,4) as int)) as max_year,
array_agg( id) as id_list
from table where hit1=''
group by hit1, hit2;
</code></pre>
<p>As the table is big, I have opted to do this one by one entity like so: </p>
<pre><code>select distinct hit1 from table limit 250 offset x
-- use above query to to store results into table.
</code></pre>
<p>This function is wrapped in another function which provides x from a loop. The function is run in a dblink context so that the results can be stored and I can audit as I go along. </p>
<p>The cycle needs to run 1,000,000, I am yet to get a number for the count of distinct hit1 values as the query takes too long to come back. The first 750 values (3 iterations) come back on the iteration in under a minute each, but at the next iteration is where it keels over. I will provide log data when this iteration dies. </p>
<p>While the query is running (at the time when the distinct list is calculated) there seems to be minimal cpu usage. There also seems to be some memory being unavailable. </p>
<p><a href="https://i.stack.imgur.com/SP72Q.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/SP72Q.png" alt="freeable memory graph"></a></p>
<p><a href="https://i.stack.imgur.com/zdy5X.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/zdy5X.png" alt="CPU utilisation chart"></a></p>
<p>Edit 2 to show results:
In the functions I use dblink for auditing. After the first 3 cycles (0-2) it takes one hour to return results from
select distinct hit1 from table limit 250 offset 750;
compared to the previous hit1 order this one is no alphabetical and it seems to return or die only 77 results in. </p>
| 0non-cybersec
| Stackexchange | 974 | 3,171 |
Does anyone else have a hard time remembering names in anime?. So I’m not like a huge anime fan but my friend recently got me to watch My Hero Academia online and I have to say, I loved it. Idk something about those characters, the balance of humor and seriousness, overall world design just really appealed to me. But after talking to my friend about it I realized I only really remembered the name of Deku (because he’s the main character and it’s a relatively short name) and Tsu (because she shouts “I said call me Tsu” like all the time to Deku). And those aren’t even my favorite characters or anything it’s just by chance I remembered them, Raven bird guy and Robo legs are probably my favorite.
I’m bad at memorizing names, even English names but for anime because a lot the the names (to me at least) sound extremely foreign and i’v never heard them before i guess they just go in one ear and out the other.
I’v had this issue with other anime’s that I actually kind of enjoyed like Soul Eater (I only remember the names of Makah? And Kid death) even though I watched that entire series.
Same with the Devil is a Part Timer, fucking loved the series, watched every episode but as of right now, I can’t remember the names of anyone. (Which is embarrassing because I think there’s only like 5 important characters)
Out of all the anime’s I’d watched, the only one where I didn’t have this issue with was Full Metal Alchemist, I think it might be the names are western are maybe they just shout them more? Idk
I’m just asking if anyone else has this issue when watching anime. | 0non-cybersec
| Reddit | 383 | 1,595 |
how to unzip same file name without override (capitalization differ). <p>I have 2 files named xt_DSCP.h and xt_dscp.h in the same directory, in a zip file. I am trying to unzip them on my pendrive but I only have 2 options: skip or override. </p>
<p>I was searching for a solution but only found how to force override but I am actually trying to do the exact opposite. </p>
<p>File system is FAT32. I know that on NTFS it is not possible but FAT32 should allow it. I already unzipped the folder successfully in linux OS. Main goal is to use it in windows, however, which is why I am trying to pass it to pen drive on linux. Any attempt always resulted in overwritten files :(</p>
<p>can someone help? </p>
| 0non-cybersec
| Stackexchange | 199 | 709 |
Guys, today is the last day we can discuss the Banned Books here at r/books! Let's make it count :D. For your reference: The List of Banned Books, and a link to [the original modpost](http://www.reddit.com/r/books/comments/21kiwz/announcement_we_are_banning_certain_books_from/).
---
> > Banned Books:
> 1. *1984* by George Orwell
> 2. *American Gods* by Neil Gaiman
> 3. *Brave New World* by Aldous Huxley
> 4. *Catch-22* by Joseph Heller
> 5. *The Catcher in the Rye* by J.D. Salinger
> 6. *Dune* by Frank Herbert
> 7. *Ender's Game* by Orson Scott Card
> 8. *Fight Club* by Chuck Palahniuk
> 9. *Gravity's Rainbow* by Thomas Pynchon
> 10. *The Great Gatsby* by F. Scott Fitzgerald
> 11. *Harry Potter series* by J.K. Rowling
> 12. *Hitchhiker's Guide to the Galaxy* by Douglas Adams
> 13. *House of Leaves* by Mark Z. Danielewski
> 14. *The Hunger Games series* by Suzanne Collins
> 15. *Infinite Jest* by David Foster Wallace
> 16. *Kafka On the Shore* by Haruki Murakami
> 17. *Lolita* by Vladimir Nabokov
> 18. *The Lord of the Rings Trilogy* by J. R. R. Tolkien
> 19. *The Name of the Wind* by Patrick Rothfuss
> 20. *Necronomicon* by H. P. Lovecraft
> 21. *The Road* by Cormac McCarthy
> 22. *Slaughterhouse V* by Kurt Vonnegut
> 23. *Snow Crash* by Neal Stephenson
> 24. *A Song of Ice and Fire* by George R. R. Martin
> 25. *The Stand* by Stephen King
---
To start the discussion: Is anyone getting a Fahrenheit 451 vibe from these?
---
Edit: [April Fools everyone! Here's the official modpost~](http://www.reddit.com/r/books/comments/21x1n8/announcement_the_banned_books_rule_is_now_not_in/) | 0non-cybersec
| Reddit | 599 | 1,636 |
Integration of $I_n=\int_{0}^{1} \frac{x^n}{\sqrt{x^3+1}}dx$. <p>Let $I_n=\int_{0}^{1} \frac{x^n}{\sqrt{x^3+1}}dx$. Show that $(2n−1)I_n+2(n−2)I_{n-3}= 2\sqrt{2}$ for all $n\geq3$. Then compute $I_8$.</p>
<p>How do I compute that integral? My idea was to reduce it to some known forms, as $\int\frac{1}{\sqrt{1-x^2}}dx$... Is there any way to solve the problem without computing the integral though?</p>
| 0non-cybersec
| Stackexchange | 173 | 405 |
how to specify session to connect to when xrdp has spawned multiple sessions?. <p>I have installed xrdp on Debian 7 like so:</p>
<p><code>apt-get install xrdp vnc4server
</code></p>
<p>I have been connecting using Microsoft Remote Desktop Connection. I have noticed that sometimes, my existing session doesn't connected if my connection drops and I reconnect, instead I get a new connection. My <code>ps</code> output shows this:</p>
<p><code>vagrant@devcloud:~$ ps x | grep -i vnc
11233 ? S 0:03 Xvnc :11 -geometry 1440x900 -depth 16 -rfbauth /home/vagrant/.vnc/sesman_vagrant_passwd -bs -ac -nolisten tcp
12404 pts/5 S 0:01 Xvnc :12 -geometry 1440x900 -depth 16 -rfbauth /home/vagrant/.vnc/sesman_vagrant_passwd -bs -ac -nolisten tcp
12855 ? S 6:13 Xvnc :10 -geometry 1600x900 -depth 16 -rfbauth /home/vagrant/.vnc/sesman_vagrant_passwd -bs -ac -nolisten tcp
</code></p>
<p><strong>Question:</strong> Is it possible to specify the session to connect to, rather than a new session being spawned?</p>
| 0non-cybersec
| Stackexchange | 351 | 1,039 |
AITA for not allowing my 11-year-old daughter to have a boy sleep over our house?. As I said, my daughter’s 11 and her friend group ranges 11-12. It’s mainly girls but there is one boy that I have seen around.
She’s having a sleepover to celebrate her birthday this weekend. She invited the boy to the party but the plan was (or so I thought) that he would leave around 10 pm.
The boy’s mom called me last night to confirm that the boy (I’ll call him Tom) could sleep over. I said there must have been some miscommunication and I thought that she was picking up Tom at 10. I told her that if transportation was a problem my husband or I could drive Tom home.
Tom’s mom said that the issue was Tom wanted to stay over and would be let down if he had to go home. (Again, I don’t know why she thought he was sleeping over, since I made it clear on the invitation what was expected. We will have a couple other boys over who are the kids of family friends and they will also be leaving at 10 pm!).
It was a sort of awkward conversation to say the least. But she ended up saying she would come to pick up Tom after the party.
To be honest, even if I was inclined to have Tom sleep over, I doubt husband would go for it. But I’m starting to wonder if I did something wrong here? | 0non-cybersec
| Reddit | 316 | 1,282 |
Locked out by permissions on an internal 4TB drives problem. <p>This is my 2nd time around with an internal 4 TB drive or greater. And I seem to have continuous problems with permissions. I also had as problem with an external 6 TB drive and permissions. This has been happening on different computers. All were all running a Linux system. All drives were running an EXT4 system. I seems to have solved the problem with the external drive by formatting it as a NTFS files system.</p>
<p>However, on internal drives, I should be able to run them as a EXT4 files system. What happens is that I format them, then loose permissions to them after I re-boot. I can access them, but can not do anything else. I can not post files to them or create internal directories.</p>
<p>I've had the same problem with Ubuntu Gnome and Mint. What do I need to do, format them as NTFS drives?</p>
<p>I have tried the various 'chrown' and 'chmod' commands with various settings. No help. I get the message that permissions have been changed, then I access the drive. No change.</p>
<p>On one computer, my home directory was encrypted. On the other computer, it was not.</p>
<p>All hardware has been replaced and updated. New CPU. New motherboard. New power supply. New memory. Etc.</p>
<p>Tried: cd /media/lloyd/SyS_10</p>
<pre><code> sudo chmod -R -v 777 *
</code></pre>
<p>No help</p>
<p>Tried: cd /media/lloyd/SyS_10</p>
<pre><code> sudo chown -R -v lloyd:lloyd *
</code></pre>
<p>Again, no help.</p>
<p>Also tried some other things, which did not help. But can't remember the sequence.</p>
<p>Common points between them:</p>
<ol>
<li><p>Running a Linux system. Different flavors and different computers. (Ubuntu Gnome 17.10 and Mint 18.3.)</p></li>
<li><p>Drives formatted as EXT4 (BIOS supports large drives.)</p></li>
<li><p>Drives were equal or greater than 4 TB.</p></li>
</ol>
<p>Common problems:</p>
<ol>
<li><p>Assigned all permissions to these drives to ROOT.</p></li>
<li><p>All stated that I did not have ROOT Permissions.</p></li>
</ol>
<hr>
<p>It appears to me as if there is a bug in either Ubuntu or EXT4 when using multiple drives and those additional drives are larger than 2 TB. (I am leaning towards thinking that the bug is in EXT4 where the additional drives are larger than 2 TB.) This bug does not seem to affect the main drive. Sda1 or sda2 drive.</p>
| 0non-cybersec
| Stackexchange | 711 | 2,381 |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange | 349 | 1,234 |
How to add sticky bit to a directory in exFAT?. <p>I get this error from <code>Homebrew</code> when trying to build an application on MacOS 10.10.5, on an exFAT filesystem</p>
<pre><code>Error: parent directory is world writable but not sticky
</code></pre>
<p>I use this command to enable sticky-bit, but there does not seem to have any effect</p>
<pre><code>$ chmod +t /Volumes/exFAT/tmp
</code></pre>
| 0non-cybersec
| Stackexchange | 133 | 407 |
What happened to the boy [Part 3]. [PART 1](https://www.reddit.com/r/nosleep/comments/56iuya/is_any_of_this_normal/) [PART 2](https://www.reddit.com/r/nosleep/comments/58d70e/mother_left_the_corner_part_2/)
~Dear reader,
I am the one you’ve come to know as Uncle. I have been posting the Nephew stories to you over the past month or so. What follows is what would become Nephew’s last account of his time within the domicile. The boy was too kind for the world he was brought up in. Kindness leads to destruction in a place like this, as I know too well myself. I hope this last piece of the story brings peace of mind and understanding.~
It has been so long since I last reached out to you in your other world. Uncle returned immediately after I finished my last message but he would not look at me. His eyes remained fixated on the thing in the corner. I tried to ask him about it but he wouldn’t listen. A profound sadness welled up in his eyes as he stared.
After a short while he reached out towards me with his hand, imploring me to share my note with him. I did and he took his leave. I have not seen Uncle since. I want to believe he’ll return but I can’t be certain.
Everyone has left now.
I almost thought Father would never leave me. My constant captor. But he did.
First Mother, then Father, now Uncle. All there is left is me and the thing in the corner. Although I don’t think I could call it that anymore, it has grown to fill the domicile almost entirely. It is everywhere, on the ceiling, across the floor, over the window. The only place it isn’t is Father Corner, where I sit wedged in the spot where Father once vigilantly watched over me.
I can’t know for sure where Father went. He just disappeared one day. I woke up and he was gone. That was the moment the whole situation sunk in. I may have been living with a faceless, writhing creature slowly oozing out of the corner that Mother once stood in but at least I wasn’t facing it alone. The true horror lies in the loneliness. Although Father frightened me at the best of times I always believed he would protect me from the thing. He may not have been able to see it but I believed his presence was enough to keep it at bay. Maybe I was right, but now I’ll never know.
I believe that seven days have past since I last saw the face of Father. I hold no hope of seeing him again. As for Uncle, the thing is stretched across the window where he once stood. I once thought I saw his silhouette peering through the thing’s fleshy mass of veins and cartilage but I can’t know for sure. He too has abandoned me. I write this note not for his sake but for my own. I don’t expect him to find it once this is all over and I don’t expect anyone to read it. I am only keeping up this charade in order to stop myself from looking directly into the thing that now surrounds me at every side. For if I did I would surely go mad.
To write is to keep my mind active, to keep my eyes away from the thing that even now I can hear pleading with me to look in its direction. It’s speaking to me, but not quite. There are no spoken words, only pulses of thoughts. It’s in my head, whispering to me slowly and rhythmically so that I look at it. I don’t want to, but I will eventually. I know it. I’ll try to fight it as best I can for now but It won’t be long I’m sure. Mother is gone, Father and Uncle were close behind. Nobody is coming to save me from this thing. I’ll either die writing in this corner or do as it wants. Then I’ll probably die anyway, or worse.
I can see it peripherally, bending about the room with its limbs broken around every corner. I dare not look into its core. That bloated centre mass in the corner hanging like a mutated shadow of the woman who once stood there. How could she leave me? Did she ever even love me? I’m her son.
The thing in the corner is shifting, those mangled branches inching ever closer to where I sit and write this note. The only way I can truly describe it is to call it wrong. A thing that belongs neither in this world or the other. I dare not wonder what lies beneath its bubbling and twitching skin. When I think of it I imagine the ways in which it could take me. At any moment one of those horrible extremities could reach down from anywhere and snatch me up. But it hasn’t. I’m not certain why, possibly because it likes taunting me with its disfigured shape. Playing with me.
Maybe I could peek at the thing very quickly. So fast that it won’t even notice I was ever looking. Yes, I think that might work. I’ll look and immediately look back to the page to jot down what I see. This will work. It cannot know I looked. But I will.
I looked.
I remember the day I was brought here. I remember my birth. The thing told me. As soon as I looked, I knew.
The thing has a name, one I cannot write. It is too long and too old, but I know that the thing is not just a thing. It is no more a thing than you or I could be considered a thing. It has consciousness, a mind, a capacity for complex thought, a family, a lineage, a home, a domicile, a name.
It was January 8th. The moon was indeed pale but I was not born under it. It was visible through the window. The window where nobody stood, no Uncle. This domicile was different, it was wholly white and clean. The creatures around me were not shrouded in shadow, they were in the light, staring down at me with happy faces. Except for Mother. Mother was there in the shadows under every bed, behind every door and in every corner. The thing with a name was there too.
I remember it as a happy place. I know that changed once I left. Once Mother stepped forward to carry me across the fields and into the domicile. Mother and the thing with a name robbed the place of its happiness, they robbed it of me.
Mother took me back to the domicile where I now sit and write this note. I do not know how different my life would have been if the happy people had kept me in their bright, beautiful domicile, but something about the memory of that place feels right. It feels like home.
Father didn’t know about Mother’s plan to take me, to raise me in the domicile. When Mother entered with me in her arms he initially tried to return me to the happy people. That's when the thing with a name made itself known, he knew he couldn’t fight it. So he made the decision to keep me, for that is what Mother wanted, or what the thing with a name made her want. He decided to raise a son he knew was not his own, a son who was not even from his own world. He was forced to serve the thing with a name.
The thing that has had many names over its long life. The thing I knew as Mother.
Mother didn’t leave the domicile, she only turned her back to it. She’s still here. Behind the thing with a name that grew inside her for so many years. The thing that told her to take me from the loving arms of the happy people. The thing that Father tried to protect me from, the thing that stole him away into the contorted lump of flesh it calls a body. The thing that scared Uncle so much that he fled, abandoned me to the mercy of this thing. This thing that has a name.
I must go to it now. I saw into the eye of the thing and it showed me my past, but it also showed me my future. In it I join Mother and Father inside the thing. So that is what I must do.
I don’t expect Uncle to ever return to the domicile, so my tale will go untold. But if he should, I’d like him to know that I understand why he did it. His cowardice has spared his life. In exchange for mine. I forgive you Uncle.
And to you my friend from another world, I expect you are worried for me but you should not be. The thing with a name knows all and this is the way it should be, the way it has always been. Maybe we will meet one day, when the thing with a name comes to you. Until that day, I wish you the best. Now I must join my family.
~This is where the boy’s note ends. I retrieved it from what was left of the domicile. I am deeply sorry.
Sincerely,
The one you know as Uncle.~
| 0non-cybersec
| Reddit | 1,999 | 8,045 |
Recovering broken Ubuntu installation. <p>I have not updated Ubuntu for quite some time and then I went from version 15.04 to 16.04 (which succeeded) and then immediately I tried to go to 16.10. This however failed mid-upgrade and the installation got corrupted (I can "log in" but do nothing, recovery mode does not work).</p>
<p>Using USB boot, I managed to get to the filesystem with the intention to recover my date, however I encountered the problem that some of them are apparently protected and I do not have the rights to do basically anything with them. Is there a way to:</p>
<p>1) Copy them using live USB to a backup, so that I can simply format the partition and reinstall the system? Of course I do remember the login/password to the previous installation?</p>
<p>2) Install Ubuntu over the previous one without formatting, thus preserving the old data and be able to access them (even though they originate from a previous instance)?</p>
<p>Also please bear in mind that I am just a regular user with regards to Ubuntu, so any instruction will have to be probably fairly specific:)</p>
| 0non-cybersec
| Stackexchange | 263 | 1,105 |
How to use takeWhile with an Iterator in Scala. <p>I have a Iterator of elements and I want to consume them until a condition is met in the next element, like:</p>
<pre><code>val it = List(1,1,1,1,2,2,2).iterator
val res1 = it.takeWhile( _ == 1).toList
val res2 = it.takeWhile(_ == 2).toList
</code></pre>
<p><code>res1</code> gives an expected <code>List(1,1,1,1)</code> but <code>res2</code> returns <code>List(2,2)</code> because iterator had to check the element in position 4. </p>
<p>I know that the list will be ordered so there is no point in traversing the whole list like <code>partition</code> does. I like to finish as soon as the condition is not met. Is there any clever way to do this with Iterators? I can not do a <code>toList</code> to the iterator because it comes from a very big file.</p>
| 0non-cybersec
| Stackexchange | 261 | 813 |
Love is Rewatch! The Series Finale for the Kaguya-Sama: Love is War Rewatch - EPISODE 12 DISCUSSION. ​
https://preview.redd.it/djtuhosukur41.jpg?width=1242&format=pjpg&auto=webp&s=54c7796265a8090859f2bd189d43b138538e5507
# [12 - I Can’t Hear the Fireworks Part 2, Kaguya Doesn’t Want to Avoid Him](https://imgur.com/8pgvlYF)
[<< Previous Episode](https://www.reddit.com/r/anime/comments/fxdrcp/love_is_rewatch_a_rewatch_for_kaguyasama_love_is/?utm_source=share&utm_medium=ios_app&utm_name=iossmf) | [Index Thread](https://www.reddit.com/r/anime/comments/fql4ej/kaguyasama_love_is_rewatch_24_hour_reminder_and/?utm_source=share&utm_medium=ios_app&utm_name=iossmf) | [Overall Series Discussion >>](https://www.reddit.com/r/anime/comments/fynl9i/love_is_rewatch_a_rewatch_for_kaguyasama_love_is/)
**Show Information:** [MAL](https://myanimelist.net/anime/37999/Kaguya-sama_wa_Kokurasetai__Tensai-tachi_no_Renai_Zunousen) | [ANN](https://www.animenewsnetwork.com/encyclopedia/anime.php?id=21401) | [AniDB](https://anidb.net/anime/14111) | [AniList](https://anilist.co/anime/101921/Kaguyasama-wa-Kokurasetai-Tensaitachi-no-Renai-Zunousen)
**Subreddit:** r/Kaguya_sama
**Discord:** [Invite Link](https://discordapp.com/invite/skEjP4u)
​
https://preview.redd.it/w4c0bqyhjur41.jpg?width=1242&format=pjpg&auto=webp&s=8fea7ef5577c3808cfbb0312cd4bab8d604a9b58
u/Regular_N-Gon for his great comment and and question about one of the episode title
>Hayasaka continues to be fantastic. I kinda feel bad for her, but she must get paid a lot to deal with Kaguya's insanity. And, by the end of the episode, it's clear she does care at least a little for Kaguya despite the amount of work she is.
[Read the rest of the comment here!](https://www.reddit.com/r/anime/comments/fxdrcp/love_is_rewatch_a_rewatch_for_kaguyasama_love_is/fmtqsdu/?utm_source=share&utm_medium=ios_app&utm_name=iossmf)
​
u/NicDwolfwood for his thoughts and reaction to yesterday’s episode
>Kaguya being terrible with tech is hilarious, she barely knew what Twitter is lol and how it works. Hayasaka puts up with alot dealing with Kaguya, she couldn't even enjoy her bath in peace.
[Read the rest of the comment here!](https://www.reddit.com/r/anime/comments/fxdrcp/love_is_rewatch_a_rewatch_for_kaguyasama_love_is/fmtskod/?utm_source=share&utm_medium=ios_app&utm_name=iossmf)
​
https://preview.redd.it/xeidrqvljur41.jpg?width=1242&format=pjpg&auto=webp&s=0ab99754d04f7b0486eb0b3bc7af00e00a3711e2
**QUESTIONS:**
**1.** **Do you perceive the things Shirogane said as cool or cringe?**
**2. What about that ED though?**
**3. Not a question, but I’d like to get an estimate on how many people were in the rewatch. People who commented on threads and people who followed along too. Please do the poll:** [**https://www.strawpoll.me/19735930**](https://www.strawpoll.me/19735930)
​
[Hanabi?](https://preview.redd.it/gx0qffqnjur41.jpg?width=1242&format=pjpg&auto=webp&s=40c8431b94425592b63a58195c7ccfe297dab733)
[Source: https:\/\/imgur.com\/8pgvlYF](https://preview.redd.it/kxby5sdyjur41.jpg?width=600&format=pjpg&auto=webp&s=5e2c0108b77e23a0edd3c9f40b6fc7874560adee)
​
https://preview.redd.it/hbrxtqj2kur41.jpg?width=1242&format=pjpg&auto=webp&s=4914c3a479e56cb8ca165cf6893192f9c7e370d5
**NEWS**
**Two days until Season 2 releases!**
[Source: Official Art by Character Designer, Yūko Yahiro. Check out her twitter!](https://preview.redd.it/xh4xor6dkur41.jpg?width=1919&format=pjpg&auto=webp&s=bb32695bc9256a2edf0893af8a2aa934a02d0fc8)
​
**Rewatchers, please be mindful of first-timers reading these threads. If discussing any future events or anything, please mark them as spoilers. Thank You!** | 0non-cybersec
| Reddit | 1,512 | 3,725 |
Ubuntu server 12.04 having 7GB disk usage discrepancy. <p>I did a fresh install of ubuntu server 12.04 as a KVM virtual guest. I used a kickstart file to automate the installation, I've included the command to create the guest as well as the partitioning section of the kickstart file. These numbers were taken right after a fresh installation the only main service that is running is an ssh server. There is 7GB of disk usage that I can't account for. </p>
<p><strong>Kickstart partitioning section</strong></p>
<pre><code>part /boot --fstype ext4 --size 200
part / --fstype ext4 --size 1 --grow
</code></pre>
<p><strong>KVM installation command</strong></p>
<pre><code>virt-install -n bigtest -r 4096
--disk path=/var/lib/libvirt/images/bigtest.img,bus=virtio,size=500 \
-c ubuntu-12.04.1-server-amd64.iso --accelerate
--network=bridge:br0 --connect=qemu:///system \
--vnc --noautoconsole -v --os-type linux
</code></pre>
<p><strong>disk usage</strong></p>
<p>Running df and du reports different disk usages, which I understand can happen. The difference though of 8G vs 512M is about 7G. </p>
<pre><code>root@ubuntu:~# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/vda5 500G 8.0G 467G 2% /
udev 2.0G 4.0K 2.0G 1% /dev
tmpfs 792M 220K 791M 1% /run
none 5.0M 0 5.0M 0% /run/lock
none 2.0G 0 2.0G 0% /run/shm
/dev/vda1 188M 34M 146M 19% /boot
root@ubuntu:~# du -hs /
512M /
</code></pre>
<p><strong>Small Guest Test</strong></p>
<p>In the guest called bigtest the virtual disk was 500GB. When I create another guest called smalltest with a virtual disk of size 10GB, the numbers for df and du are 764M and 512M.</p>
<p><strong>KVM host reports</strong></p>
<p>Now if we look at the size of the kvm image files on the host file system we get another interesting story.</p>
<pre><code>root@vbox1:/var/lib/libvirt/images# du -hs *
753M bigtest.img
744M smalltest.img
</code></pre>
<p><strong>Reserved filesystem blocks</strong></p>
<p>Just to rule out other stuff as much as possible all these numbers were taken after I set the reserved blocks percentage to 0%.</p>
<pre><code>root@ubuntu:~# tune2fs -m 0 /dev/vda5
tune2fs 1.42 (29-Nov-2011)
Setting reserved blocks percentage to 0% (0 blocks)
</code></pre>
<p><strong>The Question</strong></p>
<p>What is taking up this 7GB of physical space. If it is used why isn't that being reflected in the host file system disk usage. </p>
<p><strong>UPDATE 1</strong></p>
<p>I discovered something very interesting. If you I run the following commands and reboot the new numbers for df and du are 1.1G and 875M! which are within normal expectations.</p>
<pre><code>apt-get update
apt-get upgrade
apt-get dist-upgrade
</code></pre>
<p>Here are a few observations I made about this:</p>
<ol>
<li>After a fresh install I tried rebooting many times it didn't change the 8GB usage</li>
<li>running apt-get update and upgrade don't reduce the disk usage, even with reboots.</li>
<li>only when the kernel is updated with apt-get dist-upgrade, and even then only after the system has rebooted with the new kernel will the usage drop back to normal levels.</li>
</ol>
<p><strong>UPDATE 2</strong></p>
<p>I've tested this independently in virtualbox and this same exact behaviour happens. So this issue is related to Ubuntu Server and not anything specifically related to KVM or virtualbox.</p>
<p><strong>UPDATE 3</strong></p>
<p>Some additional commands run on the machine as suggested in an answer below.</p>
<pre><code>root@ubuntu:/# du --apparent-size -sh --exclude=/proc /
963M /
</code></pre>
<p>using ncdu</p>
<pre><code>ncdu 1.8 ~ Use the arrow keys to navigate, press ? for help
--- / ----------------------------------------------------------------
230.6MiB [##########] /usr
202.4MiB [######## ] /lib
193.0MiB [######## ] /var
23.7MiB [# ] /boot
8.6MiB [ ] /bin
6.7MiB [ ] /sbin
4.9MiB [ ] /etc
220.0KiB [ ] /run
28.0KiB [ ] /root
20.0KiB [ ] /opt
e 16.0KiB [ ] /lost+found
8.0KiB [ ] /media
4.0KiB [ ] /dev
4.0KiB [ ] /lib64
e 4.0KiB [ ] /tmp
e 4.0KiB [ ] /srv
e 4.0KiB [ ] /selinux
e 4.0KiB [ ] /mnt
e 4.0KiB [ ] /home
0.0 B [ ] /proc
0.0 B [ ] /sys
@ 0.0 B [ ] initrd.img
@ 0.0 B [ ] vmlinuz
Total disk usage: 670.2MiB Apparent size: 128.0TiB Items: 54464
</code></pre>
<p>The Linux kernel versions before and after the dist-upgrade are as follows:</p>
<pre><code>Linux ubuntu 3.2.0-29-generic #46-Ubuntu SMP Fri Jul 27 17:03:23 UTC 2012
Linux ubuntu 3.2.0-30-generic #48-Ubuntu SMP Fri Aug 24 16:52:48 UTC 2012
</code></pre>
| 0non-cybersec
| Stackexchange | 1,639 | 4,930 |
Locking down external drive reads in a permanent fashion on Linux?. <p>Is there any way to alter the way a Linux distribution handles external drives to only allow read-only unless additional credentials are provided, or at least permanently disable it?</p>
<p>Basically need it such that if someone plugs a drive into a system with sensitive data, they cannot copy anything off, even with admin rights. </p>
<p>I'm working with Ubuntu 16.04 specifically, and ideally I'd need to do a bunch of setup on the system before disabling this functionality, so I'm not sure if say, modifying and recompiling the OS is possible. Ideally this needs to be a fairly difficult thing to overcome on the machine. </p>
| 0non-cybersec
| Stackexchange | 161 | 706 |
Failed to load unity-gtk-module. <p>I have some issues with unity GTK on CentOS Linux release 7.4.1708 (Core) with Gnome 3.</p>
<pre><code>$ emacs
Gtk-Message: Failed to load module "unity-gtk-module"
Gtk-Message: Failed to load module "unity-gtk-module"
$ evince
Gtk-Message: Failed to load module "unity-gtk-module"
Gtk-Message: Failed to load module "unity-gtk-module"
</code></pre>
<p>I tried installing gtk2-engines packages but it did not fix it.</p>
<pre><code>$ sudo yum install gtk2-engines*
Package gtk2-engines-2.20.2-7.el7.x86_64 already installed and latest version
Package gtk2-engines-devel-2.20.2-7.el7.x86_64 already installed and latest version
</code></pre>
<p>and reinstalling them:</p>
<pre><code>$ sudo yum reinstall gtk2-engines*
[sudo] password for klaus:
[...]
Resolving Dependencies
--> Running transaction check
---> Package gtk2-engines.x86_64 0:2.20.2-7.el7 will be reinstalled
---> Package gtk2-engines-devel.x86_64 0:2.20.2-7.el7 will be reinstalled
--> Finished Dependency Resolution
Dependencies
======================================================================
Package Arch Version Repository Size
======================================================================
Reinstalling:
gtk2-engines x86_64 2.20.2-7.el7 epel 301 k
gtk2-engines-devel x86_64 2.20.2-7.el7 epel 17 k
Transaction Summary
======================================================================
Reinstall 2 Packages
Total download size: 318 k
Installed size: 1.2 M
Is this ok [y/d/N]: y
Downloading packages:
(1/2): gtk2-engines-2.20.2-7.el7.x86_64.rpm | 301 kB 00:00:00
(2/2): gtk2-engines-devel-2.20.2-7.el7.x86_64.rpm | 17 kB 00:00:00
----------------------------------------------------------------------
Total 2.7 MB/s | 318 kB 00:00:00
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing : gtk2-engines-2.20.2-7.el7.x86_64 1/2
Installing : gtk2-engines-devel-2.20.2-7.el7.x86_64 2/2
Verifying : gtk2-engines-2.20.2-7.el7.x86_64 1/2
Verifying : gtk2-engines-devel-2.20.2-7.el7.x86_64 2/2
Installed:
gtk2-engines.x86_64 0:2.20.2-7.el7
gtk2-engines-devel.x86_64 0:2.20.2-7.el7
Complete!
</code></pre>
<p>... but I still have the error</p>
| 0non-cybersec
| Stackexchange | 854 | 2,714 |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange | 349 | 1,234 |
Foilum map module, trying to get more options for marker colors. <p>I am playing with Folium a lot right now and its really great to have something so easy to use in Python. But their documentation is seriously behind, which I understand. So I have 2 questions.</p>
<ol>
<li>What am I doing wrong in how I am trying to get more marker colors? Here is what I have tried:</li>
</ol>
<p><code>map.simple_marker(each_coord, popup=v[0], marker_color='#FFFF00')</code>
<code>map.simple_marker(each_coord, popup=v[0], marker_color='yellow')</code>
<code>map.simple_marker(each_coord, popup=v[0], marker_color='Yellow')</code></p>
<p>They should all make the marker yellow, instead it stays default red. The only colors I can actually change to are red, green, and purple. In an example from the folium documentation it looks like we should be able to use html color codes:</p>
<pre><code>folium.CircleMarker([45.5215, -122.6261],
radius=500,
popup='Laurelhurst Park',
color='#3186cc',
fill_color='#3186cc',
).add_to(map_2)
</code></pre>
<p>But it doesn't work for me. Hope someone knows a way around this because I need at least 12 different colors for my project.</p>
<ol start="2">
<li>The way I am adding markers seems to be deprecated. It works, but I always get this warning: <code>FutureWarning: simple_marker is deprecated. Use add_children(Marker) instead</code> which I think might be related to why I can't get the colors to work. But their is nothing in any of the documentation or open discussions about how to use <code>add_children</code> Maybe someone with knowledge can clarify?</li>
</ol>
<p>Thanks</p>
| 0non-cybersec
| Stackexchange | 487 | 1,699 |
What are some recipes/foods that doesn't become disgusting after 5 ~ 11 hours?. I'm looking to bring my own lunch/dinner to school now due to buying food costs $12 everyday. However , my biggest concern is coming up with a meal/recipe that won't become disgusting or not edible after certain hours.
Usually I would take out the food at 7:30AM with me and I will be at school until usually 8:00PM.
around 10:30AM I usually eat almond or cheese string , at 1:00PM I grab lunch , then at 6:00PM I eat dinner.
So , if I were to pack my lunch/dinner , it would be consumed after 5 ~ 11 hours , but is it safe to eat foods that has been out for that long at room temperature(I have a locker where I can store them)?
We also have microwaves/hot water at school , so if these can of any use to improvise any recipes that would be appreciated as well.
Thank you in advance. | 0non-cybersec
| Reddit | 225 | 869 |
WHY do so many men think they can "fix" women who dislike cunnilingus?. I just starting dating a lovely gentleman. We'll call him James T. Kirk. As a sex abuse survivor, I have a little "disclaimer" that I tell people with whom I'm about to be intimate. Included in the disclaimer is this statement: "I don't like cunnilingus." A few nights ago I gave Kirk the disclaimer talk. When I was done, Kirk showed what an awesome guy he is by giving me a huge hug, threatening to hunt down and disembowel the men who perpetrated such crimes against me, and said that he will have respect and patience for whatever issues may crop up.
A few hours later we hit the sheets for the first time, and *it* crops up. You know, *it*. "I love going down on women and I'm sooooo awesome at it and I'll respect your boundaries but I really want to do it to you and I know you'll love it I promise!"
The sad part? I was totally prepared for *it* to happen, because *it* happens with almost every guy I date (and the occasional gal I date)-- they are somehow convinced that they can "cure" me of my dislike of cunnilingus and that I should let them. And I do, from time to time, let folks try. The last long-term (3 years) relationship I was in with a guy, I let him try a lot. And *I* tried. I really did try to like it. But all the pressure from him to let him try, and all the mental focus required and time (hour +) of focusing on an unstimulating physical sensation just to eek out one orgasm was-- just not pleasant. Not "OMG I'm triggered,” but more like "okay, so I am physically capable of orgasming from it, but there's 5 zillion other methods that I like a lot more."
So here I am, present day, and yet another man who is so very lovely in every other way (physically, mentally, and emotionally) wants me to let him go down on me. I want to say "absolutely not, it's on the sexual blacklist" because I'm just so sick of men thinking they can "fix" me and that it's imperative that they do. I don't want to go through another round of closing my eyes and mentally organizing my shopping list until my clitoris goes /*ping*/. At this point, it's a catch-22-- so many guys have bugged me about it that I get even more turned off to the idea whenever it is brought up.
So how do I politely explain to this man (and future men and women) that south of the border is simply out of the question?
**TL;DR** I don't like cunnilingus for various reasons and men keep trying to "fix" me; it's driving me crazy, what do I do?
**ETA:** I am more than happy to hear advice from other survivors on how to teach myself to enjoy cunnilingus. Annoyance of persistence aside, I think what "bugs" me most about it is the relative lack of physical and visual contact with my partner, which increases the change that I will dissociate and be "triggered" during the act.
| 0non-cybersec
| Reddit | 745 | 2,884 |
Unable to use CreateRemoteThread in target process. <p>I'm trying to get a debugger attached to a malware, but it seems to pick up whenever a new remote thread is created (which makes it so I can't use Scyllahide).</p>
<p>Even if I suspend all threads, it does the following:
When a new remote thread is created(<code>CreateRemoteThread</code> / <code>ZwCreateThread</code>) (internally calling <code>CreateThread</code> is ok) it patches a <code>0xC3(ret)</code> to the entry point. </p>
<p>I tried suspending it on creation then resuming it later but as soon as it is resumed the entry point gets patched before it can execute.</p>
<p>I've looked at hooks in PCHunter, there is no hooks in unnamed functions or thread related functions.</p>
<p>IDA Pro isn't helping much, the process is obfuscated a lot.</p>
<p>I don't know what should be the next step at this point, so I'm hoping someone can help me figure this out. </p>
<p>It looks like a hook or a callback is set somewhere but I don't know of any callback that gets executed on thread creation(at least in usermode) and I can't seem to find any hook related to threads in windows dll's. </p>
| 0non-cybersec
| Stackexchange | 325 | 1,157 |
How to use spot instance with amazon elastic beanstalk?. <p>I have one infra that use amazon elastic beanstalk to deploy my application.
I need to scale my app adding some spot instances that EB do not support.</p>
<p>So I create a second autoscaling from a launch configuration with spot instances.
The autoscaling use the same load balancer created by beanstalk.</p>
<p>To up instances with the last version of my app, I copy the user data from the original launch configuration (created with beanstalk) to the launch configuration with spot instances (created by me).</p>
<p>This work fine, but:</p>
<ol>
<li><p>how to update spot instances that have come up from the second autoscaling when the beanstalk update instances managed by him with a new version of the app?</p>
</li>
<li><p>is there another way so easy as, and elegant, to use spot instances and enjoy the benefits of beanstalk?</p>
</li>
</ol>
<p><strong>UPDATE</strong></p>
<p>Elastic Beanstalk add support to spot instance since 2019... see:
<a href="https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/elasticbeanstalk/latest/relnotes/release-2019-11-25-spot.html</a></p>
| 0non-cybersec
| Stackexchange | 349 | 1,234 |
context menu in thunar does not work properly. <p><a href="https://i.stack.imgur.com/9xzlQ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/9xzlQ.png" alt="enter image description here"></a>Running Xubuntu Bionic. After an update of the system that did not terminate well I cannot use my personal thunar context menus :
My context menu for searching a file in a directory does not show the type in window.
whereas the rename context menu works properly.</p>
<p>Complement : the file ~/;config/thunar/uca.xml is correct. The </p>
<p>When I right click on a directory on the context menu search file, a windows should popup in which I can type the name of the file. This window does not pop up. </p>
| 0non-cybersec
| Stackexchange | 209 | 719 |
PostGIS Intersects Query takes lot of time to get the result. <p>I am developing a webmapping application in which I used PosgreSQL with PostGIS plugin as my DB. </p>
<p>I have this two tables namely; <code>evidensapp_polystructures</code> and <code>evidensapp_seniangcbr</code>. Both tables contain geometry(multipolygons).</p>
<pre><code>-- Table: evidensapp_seniangcbr
-- DROP TABLE evidensapp_seniangcbr;
CREATE TABLE evidensapp_seniangcbr
(
id serial NOT NULL,
hazard character varying(16) NOT NULL,
geom geometry(MultiPolygon,32651),
CONSTRAINT evidensapp_seniangcbr_pkey PRIMARY KEY (id)
)
WITH (
OIDS=FALSE
);
ALTER TABLE evidensapp_seniangcbr
OWNER TO postgres;
-- Index: evidensapp_seniangcbr_geom_id
-- DROP INDEX evidensapp_seniangcbr_geom_id;
CREATE INDEX evidensapp_seniangcbr_geom_id
ON evidensapp_seniangcbr
USING gist
(geom);
ALTER TABLE evidensapp_seniangcbr CLUSTER ON evidensapp_seniangcbr_geom_id;
-- Table: evidensapp_polystructures
-- DROP TABLE evidensapp_polystructures;
CREATE TABLE evidensapp_polystructures
(
id serial NOT NULL,
bldg_name character varying(100) NOT NULL,
bldg_type character varying(50) NOT NULL,
brgy_locat character varying(50) NOT NULL,
municipali character varying(50) NOT NULL,
province character varying(50) NOT NULL,
geom geometry(MultiPolygon,32651),
CONSTRAINT evidensapp_polystructures_pkey PRIMARY KEY (id)
)
WITH (
OIDS=FALSE
);
ALTER TABLE evidensapp_polystructures
OWNER TO postgres;
-- Index: evidensapp_polystructures_geom_id
-- DROP INDEX evidensapp_polystructures_geom_id;
CREATE INDEX evidensapp_polystructures_geom_id
ON evidensapp_polystructures
USING gist
(geom);
ALTER TABLE evidensapp_polystructures CLUSTER ON evidensapp_polystructures_geom_id;
</code></pre>
<p>With my query below it takes almost 15mins. to get the result.</p>
<pre><code>-- Executing query:
SELECT COUNT(evidensapp_polystructures.brgy_locat ) as High,evidensapp_polystructures.brgy_locat as Barangay, evidensapp_polystructures.municipali as Municipality
FROM evidensapp_seniangcbr INNER JOIN evidensapp_polystructures ON ST_Intersects( evidensapp_seniangcbr.geom , evidensapp_polystructures.geom ) WHERE evidensapp_seniangcbr.hazard = 'Low' GROUP BY evidensapp_polystructures.brgy_locat , evidensapp_polystructures.municipali
Total query runtime: 896688 ms.
23 rows retrieved.
</code></pre>
<p>It is not acceptable. So, how do I optimize it? I've done spatial indexing and clustering based on this <a href="http://revenant.ca/www/postgis/workshop/indexing.html" rel="nofollow">site</a>.</p>
| 0non-cybersec
| Stackexchange | 903 | 2,601 |
First time DM-ing with all new players.. And it went great! We played Lost Mines of Phandelver. It actually went a little too well. With some natural 20's, my PC's are sitting on about 90 GP each after delivering the supplies and selling the jade statue.
Being new to DM-ing, the absolute best thing was when our rogue opened his mouth, then shut it and shook his head. I asked him what was up, and he said, "Oh, I probably can't do it, but I wanted to throw some oil on the fire and burn the goblins that are around it."
"You absolutely can. Let me roll a D4 for each one around the fire." It was amazing when they did something off book at first. | 0non-cybersec
| Reddit | 165 | 653 |
Server 2003 dnscmd.exe access denied (not server 2008). <p>The only topics I can find on dnscmd.exe access denied are all "when we upgraded to Server 2008 this error started". Well, I'm using Windows XP client and Server 2003 and getting this error. I can use computer manager to view sessions, open files, services (start/stop works also) from my XP workstation, but when I try to use the DNS Manager snap-in or dnscmd.exe I always get Access Denied (5) error. I have confirmed that RPC over TCP/IP is enabled for the DNS service (when I disable I get a connection reset error instead).</p>
<p>More info on setup:</p>
<p>DNS Server:</p>
<pre><code>Windows 2003 Standard Edition SP2
Computer Name: PSServer
Workgroup Name: TELEXSI
</code></pre>
<p>Workstation using dnscmd.exe:</p>
<pre><code>Windows XP Pro SP3
Computer Name: DEVELOPER
Workgroup Name: TELEXSI
</code></pre>
<p>DNS command-lines tried:</p>
<pre><code>dnscmd.exe mydomain.com /Info
</code></pre>
<p>Also tried using the IP (it is an external/Internet IP) instead of domain name.</p>
<p>In computer manager when I view the list of active sessions, I see my XP workstation listed (by its external IP) and the user name is a user in the admin group, and not as guest. This is the one and only login we use for everything, start/stop services, install software, etc, so I know it has full-access/admin rights.</p>
<p>Is this a known restriction of a Workgroup over WAN? Seems odd that I can do everything else remotely, but this one area (DNS Server) I am having issues with.</p>
| 0non-cybersec
| Stackexchange | 457 | 1,557 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.