question_id
int64
1
1.16M
title
stringlengths
10
191
question_body
stringlengths
6
2k
answer_body
stringlengths
0
2.5k
tags
stringclasses
73 values
question_score
int64
-15
1.65k
answer_score
int64
0
2.91k
view_count
int64
4
1.24M
creation_date
stringdate
2008-08-01 18:45:00
2025-06-19 04:44:02
category
stringclasses
12 values
source_site
stringclasses
8 values
885,708
What faster proxy_pass or redirect to resource
I transfer my website to new webserver, without assets. I have flolowing links: [CODE] on new website but now, it's got 404 error also I have old server with images on the same paths, it's look like [CODE] I have two options: use proxy_pass to get images by old paths from [CODE] use redirect to redirect queries for ima...
proxy_pass is probably the better way to do this as you are presumably updating links and moving images to the new server. A redirect should also return a status response of some kind which could cause problems for search.
0
0
78
2017-11-29T12:05:19.833
infrastructure
serverfault.com
371,133
For-if antipattern
I was reading on this blog post about the for-if anti-pattern, and I'm not quite sure I understand why it's an anti-pattern. [CODE] Question 1: Is it because of [CODE] inside the [CODE] ? or the fact that you don't need a [CODE] loop in this case? As the author of the blog pointed out the less crazy version of this is:...
This is an antipattern as it takes the form of: [CODE] and can be replaced with [CODE] A classic example of this is code like: [CODE] When the following works just fine: [CODE] If you find yourself performing a loop and an [CODE] or [CODE] , then stop and think about what you are doing. Are you overcomplicating things ...
9
8
1,880
2018-05-18T15:57:47.960
api_errors
softwareengineering.stackexchange.com
848,028
Max number of shares on windows server 2008r2?
Is there a maximum number of shares that can be active at one time on windows server 2008r2? I'm struggling with a weird issue with shares disappearing on a file server with about 2000 shares on it and can't figure out why they are working one day and not the next. Additional info, How they are dissappearing is they we...
Shenan Stanley has expressed this well in words on similar Microsoft Community Question : Like prior editions of Windows Server - no max . Although after a certain point the administrator may want to rethink their model if they have so many shares they need to ask such a question. ;-) Now, you seem to have a model wher...
2
1
3,298
2017-05-03T14:48:06.290
infrastructure
serverfault.com
247,072
Preventing duplication on a Postgres table with 2 columns
I am currently implementing a simple database schema (in PostgreSQL 11.1 (Debian)), with two int columns (say col1, col2). My goal is to prevent duplicates appearing in any of the two columns. If (1,2) already existed, then (1,2) or (2,1) would cause a "duplicate key value violates unique constraint" error. For a pract...
Enforce a particular canonical ordering on the values: [CODE] If they are in the wrong order, the check constraint will reject them. They are in the correct order the unique constraint will. You could couple this with a BEFORE INSERT trigger to swap the order, if you don't want to force the application to deal with tha...
1
2
1,753
2019-09-05T14:57:30.717
data_quality
dba.stackexchange.com
110,426
Using Microsoft Office software as part of my web service backend?
What licensing issues arise if I install and use Microsoft Office software (in this case Visio) as part of my web service backend? My company's flagship piece of software can convert Microsoft Visio files for use in their environment, but of course requires a local install of Visio to decode the files. The system I'm t...
If you have a single license per each web server that should be fine. Technically, your software/the website user identity is using the software. So long as you don't distribute Visio through the site you are OK. If you look through technet/MSDN, there are many articles about automating office on the server side, so th...
0
2
339
2011-09-24T18:06:01.377
api_errors
softwareengineering.stackexchange.com
393,078
Apache server Website should point to Vhost but is searching in html folder on upgrade
I upgraded my server from 2.2 to 2.2.22 . When I open my website in chrome it says successfully installed and [CODE] But earlier the 2 site which were hosted on the server were at [CODE] During the upgrade i encountered an error error: unpacking of archive failed on file /usr/lib64/apr-1/build: cpio: rename failed - Is...
Try maybe moving the stuff from /var/www/vhosts/sitename/httpdocs/httpdocs to /var/www/html and see what happens ?
1
0
162
2012-05-27T08:27:33.643
hadoop_errors
serverfault.com
1,075,246
Linux cli pipeline command tail and grep
I am using tail to monitor a log file and using grep to filer the keyword. [CODE] is working [CODE] is working but if to put them together is not working, like [CODE] Is this the wrong way to use [CODE] ? How to make [CODE] to work? Thanks if I want to run a command after awk like [CODE] how to achieve something like t...
You can do it with [CODE] alone: [CODE]
0
1
66
2021-08-21T07:45:45.973
pipeline_ops
serverfault.com
784,734
How make Docker auto-survive kernel upgrades and restart?
Brief question: Docker, Ubuntu 16.04, auto-security-upgrades & reboot. Then how can I ensure the newest linux-image-extra-`uname -r` has been installed before Docker attempts to start the containers after an auto-security-upgrade-and-reboot? Detailed question: (everything below) I'm using Docker and Docker-Compose to d...
You have to install the virtual package for the current kernel. [CODE] should be a dependency then. So when you have installed the generic kernel, you should have the [CODE] package installed. It depends on the current [CODE] as you can see here . This is not a normal problem by the way. It should usually just work.
0
2
1,969
2016-06-18T06:16:57.317
pipeline_ops
serverfault.com
237,022
Oracle - Sync Sequence nextval using CONNECT - side effects?
DB Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Action After a data migration - from an old table to a new table - we created a new sequence and executed this command to sync it's next value to be equal to table maximum id. SQL [CODE] Question Is there any side effect on calling this SQL - since th...
[CODE] in this context has nothing to do with database connections. hierarchical_query_clause ::= You can change the increment of a sequence to set it to a required value. Example: [CODE] You can also use the undocumented [CODE] clause, but that does not work in 11.2: [CODE]
1
2
818
2019-04-30T10:35:06.970
database_errors
dba.stackexchange.com
786,817
Factory reset Windows Server 2012 R2 Standard Virtual Machines
I have two Windows Server 2012 R2 Standard Edition Virtual Machines running on a Windows Server 2012 R2 Standard Edition with Hyper-V role. As a student, I've been playing around with the virtual machines and trying various modifications to test its performance. When I first installed it, both vms automatically validat...
I discovered there are two ways to reset Windows Server 2012 R2 Run the dvd installer with the Windows installation in place. There is no option for a clean install but it does wipe out the previous Windows installation and preserve the key (even though it asks you to enter it at the beginning). The second method is to...
0
1
33,802
2016-06-29T02:44:10.373
infrastructure
serverfault.com
443,394
How to block a user from accessing SharePoint that's on a group with permissions to access
Example: I added to Readers my 'DOMAIN\domain users' on SharePoint. I want to prevent user JOHN to access my SharePoint site, is there any way of doing that in SharePoint, without going into AD? Like creating a no access permission and add that user with that permission? I have tried that but didn't work, any ideas or ...
SharePoint uses the least restricctive at the collection level so you can prevent access entirely by goin into your central admin and changing the policy to deny all on the particular user. At the collection level though, you'd have to apply more specific permissions or change AD to get what you're looking for.
1
2
3,481
2012-10-29T15:07:03.813
infrastructure
serverfault.com
64,052
File size mismatch
What's the reason behind the difference in reported file sizes? [CODE] This came to our attention when a server's backup kept failing for quota issues, so it wasn't only "ls" which was seeing this wrong size. Terms like "sparse files" and "block assignment" are coming to mind, but I'm not sure why it would happen or th...
The difference between the values is as follows. From the manual of stat(2) [CODE] The st_blocks field indicates the number of blocks allocated to the file, 512-byte units. (This may be smaller than st_size/512, for example, when the file has holes.) The size as reported by ls is [CODE] , the size as reported by du is ...
4
10
3,194
2009-09-10T08:49:19.827
database_errors
serverfault.com
133,992
Failover Internet connection?
In my Linux server i have three network cards. The eth0 card is connected to ISP1, the eth1 card is connected to LAN and the eth3 card is connected to ISP2. What i want to do is to automatically use eth3 as Internet connection if the eth0 connection fails. How can this be done? Another problem is that my firewall is re...
Here's a link you might find helpful if your network is simple enough: Fallback gateways . For more complicated situations, you'll need solutions like Quagga , an implementation of OSPF protocol for Linux.
4
2
2,833
2010-04-20T06:54:58.797
database_errors
serverfault.com
388,049
I accidentally overhauled someone's entire project. Any acceptable way to pull request?
I found a great project on github with a useful central feature but which is rough in the "polishing" of error handling, logging, config, and setup. The project is 5 years untouched, and only a couple hundred lines of code. Still it's useful enough to have brought itself attention for a decent number of watchers and a ...
If the project was "5 years untouched" as you wrote, it is likely that pull requests are not going to be accepted, regardless if someone fixed a typo in a comment or did a complete rewrite. The project was probably abandoned by the original authors. The first thing I would try is to contact the authors and ask them wha...
13
31
1,099
2019-03-05T03:49:41.127
api_errors
softwareengineering.stackexchange.com
121,207
Insert query optimization
Need your help optimising an insert query. I have two tables in my MySQL DB. I will be inserting into Table1. Information will be retreived in Table2. Table 2 contains a couple of million records. My insert query should look for all users who has a previous event in Table2 and insert it into Table1. This is my insert q...
not in (Select f.EventID from TABLE1 f) optimizes poorly. Turn it into a [CODE] : [CODE]
0
0
70
2015-11-16T09:51:58.340
database_errors
dba.stackexchange.com
543,725
Can't start MySQL 5.6 installed via macports on OS X 10.8.5 (new install errno: 13 - Permission denied)
I've been Googling and banging my head against this one for quite a while now. I have not installed MySQL on this system before and just installed version 5.6 via MacPorts and have run [CODE] following the port installation. I couldn't get the server to start though. To diagnose the problem, I tried running [CODE] and ...
Log in as root and execute: [CODE]
4
5
4,340
2013-10-04T05:04:39.197
database_errors
serverfault.com
441,373
ASP.Net Web Application doesn't work - IIS7 configuration or install issue?
Obligatory background information: I'm a developer and I recently got a new workstation. My attempts to get my companies' main web application working have utterly failed. I have gone through all of the steps necessary to configure it and get it working in IIS-7 (except it isn't working). Facts of note: It is a .net 3....
It turns out Static Content was not installed (under World Wide Web Services\Common HTTP Features). That fixed it.
1
1
534
2012-10-23T14:27:36.837
api_errors
serverfault.com
12,641
Apart from testing and finding good bugs what other things the testers can do?
As far as testers are concerned, apart from testing the application thoroughly and finding good bugs, what other factors are there/ or what other things the testers can do which can prove their worth within the scope of a project. This can be junior or senior testers both including the test lead.
Here are some ideas (not exhaustive, as is never the case with testing). On a higher level, contribute to establishing a test strategy, master test plans, etc. Static reviews of analysis documents and requirements ! This implies finding defects before they're even developed. Testing at its most valuable. You're really ...
2
6
319
2015-04-11T13:51:09.470
data_quality
sqa.stackexchange.com
318,167
searching for powerfull monitoring tool for production servers
Possible Duplicate: What tool do you use to monitor your servers? I'm searching for a monitoring system that has the following features: targeted for Amazon EC2 scalable custom plug-ins can be added, prefer python installation and configuration can be automated integration capability with other monitoring, log systems ...
In my personal experience, Zabbix is a great monitoring tool. It will reach out to the agent and pull requested data of what you want. You can then use either php/perl/python/bash etc. to create scripts that can return data from the Zabbix client to your Zabbix monitoring server, and it also accept parameters by defaul...
0
1
155
2011-10-04T01:14:32.220
data_quality
serverfault.com
4,421
Why a copy of my.ini of other MySQL installation not working on my PC
I have two MySQL installations on two different PCs not connected to each other. I made some changes in the my.ini file of PC 1 and tried using this file on PC 2, but MySQL service fails to start. Why the copied My.INI not working on my PC when both installations were configured same and the instance names also similar...
First, let's make sure MySQL evens runs properly apart from the service. Open a DOS Window Session and run these commands [CODE] When you launch mysqld like this, mysqld expects my.ini to be in the parent directory , which is C:\Program Files\MySQL\MySQL 5.5. Using start in DOS will open another DOS Window as a backgro...
1
1
2,164
2011-08-06T17:15:26.123
database_errors
dba.stackexchange.com
13,716
Remove nulls from TSQL connection string
I have a bunch of queries, against a couple different databases, that I use to generate delimited reports. I'm trying to create some new reports against a MSSQL database and I'm having trouble replicating our other processes to get consistent results. When I query against the other sources I get '' and 0 in place of nu...
SQL Server always returns NULLs in this case. I know of no way to globally (through server settings or connection strings) cause it to return empty strings or zeroes instead of NULLs. And I do not think it is a database library issue--using different drivers won't change a thing. This is just the way SQL Server behaves...
4
2
753
2012-02-23T03:35:37.490
data_quality
dba.stackexchange.com
10,912
SQL Server Transaction Timeout
Is there a way in SQL Server 2008 R2 to cause a timeout for a database modification involving a transaction? We have a scenario where our application code hangs or throws an exception and fails to perform a rollback or commit. This then causes other sessions to hang waiting for the transaction to complete.
Extending Mark's answer... When a client timeout event occurs (.net CommandTimeout for example), the client sends an "ABORT" to SQL Server. SQL Server then simply abandons the query processing. No transaction is rolled back, no locks are released. Now, the connection is returned to the connection pool, so it isn't clos...
13
24
49,562
2012-01-18T22:44:07.857
database_errors
dba.stackexchange.com
402,930
Do authorization checks belong in the controller or the repository/persistor
I have a Laravel project where the controllers (all derived from one of two base controllers) use repository and persistor classes to interface with Eloquent models. Authorization logic is implemented in policy classes but the actual check needs to be made either in the base controllers or in the repository and persist...
You may try middleware or controller. Middlewares would provide a better and centralized control mechanism which may be used in multiple controller methods. Any class besides controller/middleware would be reasonable if you have non-http related actions.
1
2
272
2019-12-25T09:47:41.800
api_errors
softwareengineering.stackexchange.com
165,547
Using newly inserted values in trigger function in PostgreSQL
I have this table: [CODE] And I need to update each user's balance after inserting rows to 2 different tables, [CODE] and [CODE] . I've created 2 functions to calculate new user balances and updating it: [CODE] But I'm not sure how to use the newly inserted values in a trigger callback, because I need to pass the [CODE...
Within the trigger function you can use NEW.column_name to refer to the newly inserted / updated value. In the reverse, OLD.column_name will refer to the value prior to the update / delete. More info here: https://www.postgresql.org/docs/current/static/sql-createtrigger.html Hope that helps.
6
6
13,759
2017-02-26T14:17:14.837
database_errors
dba.stackexchange.com
282,802
Database structure
I've been searching for a while how to solve this problem, and finally I've decided that maybe it's better to ask for some help. We have two different application (app1 and app2), each of them with a different database (db1 and db2). Then we have another project to manage those applications data using both databases. T...
It is possible to query across multiple databases in SQL Server if all the databases are on the same instance, or there are linked servers set up between them. The login would need access to all the databases. For your design question, I think having a third database for the separate concern of the client connections m...
0
0
101
2021-01-08T08:23:45.270
data_quality
dba.stackexchange.com
1,093,645
satadimm reliability as the server operating system
I have seen little information about satadimm. I bought a server for a colocation and it came with a viking 400gig satadimm, the first time for me. I thought this was pretty cool, and I was told you can load your OS and save your RAID slots for more mirror or whatever. My best practice is to have my server OS on a mirr...
It's not RAM. It's just a SATA drive in DIMM form factor, powered by the RAM slot, attached via a separate cable to the storage controller. It's convenient when you have spare RAM slots - at least according to the marketing. It behaves like SSD storage, because it's SSD storage.
0
0
24
2022-02-14T17:53:02.947
infrastructure
serverfault.com
298,999
What is the best data model to represent mathematical range (in database, xml, json...)?
For example, greater or equal to 50 and smaller than 100 (>=50 && smaller than 10 or greater than 40 ( 40) I have been thinking about how to represent mathematical range in a file and database, the range may be input by non programmer and I need to keep the input simple, but at another side, it also need to keep the in...
If you're working solely with integer ranges, you're probably over-thinking the problem. All you need to store is the lower bound and the upper bound, and use a fixed rule about whether the bounds are inclusive. For example, Python ranges tend to use a half-closed interval, so that: [CODE] Is what mathematicians would ...
3
7
5,357
2015-10-05T02:34:38.743
api_errors
softwareengineering.stackexchange.com
1,023,508
Connect CloudSQL instance using Private IP via Cloud VPN Tunneling
I have two projects 1 and 2 and two vpc networks vpc1 and vpc2 in the respective projects. I need to connect to sql instance in vpc2 (project2) from vm in vpc1 project1 using private IP. After trying diiferent methods and exploring options like vpc peering, cloud NAT (which wouldn't work for me) I found the cloud VPN s...
From the documentation that you are referring to, you can follow the console instructions instead of the gcloud ones to get a little more information on that step (the equivalent is step e) . As per the intruction, you can find the the IP range by navigating the left sidebar to VPC Network > Routes, and I believe that ...
0
0
401
2020-06-30T17:40:34.687
infrastructure
serverfault.com
996,967
Is it possible to let nginx run as a different user for a location?
My nginx is running as user nobody:nogroup. But I want a certain location of server clause to be protected and owned by specific users. Basic Authentication is easy enough to set up, but the permission of the actual directory is not world-readable so unavailable for nginx and I get a 403 Forbidden error. Can I tell ngi...
No, it is not possible to change the user during run-time. When nginx starts, it does initialisation work as root user, and after that it drops privileges to become a non-privileged user. After that point, it is not possible to change user anymore. I suggest that you assign nginx group to the directory. For example, if...
1
2
1,671
2019-12-28T17:59:45.240
api_errors
serverfault.com
28,272
Can I do anything about a very long running KILL command?
I've got a table with 103M+ records in it and takes up 70GB on the disk. I decided to DELETE (in one statement) 70% of the records. As expected, this took an awfully long time to run. I decided to KILL that DELETE command before it finished (although it had been running for approx. 350K seconds, as shown by SHOW PROCES...
First of all, thank you posting the DELETE query and the table layout With regard to your question, there is nothing you can really do because a rollback is being done via the UNDO tablespace inside ibdata1 (it should have grown immensely). If you kill the mysqld process and restart it will just pickup where it left of...
3
4
13,041
2012-11-06T17:26:25.137
database_errors
dba.stackexchange.com
98,289
How do you research and list up thinkable encoders and decoders when you build NLP models?
I'm a beginner in NLP and deep learning fields, and have stacked with the phase how research and list up available and substitutional encoders and decoders. For example, I read a thesis that Bidirectional [CODE] and [CODE] were selected for named-entity recognition, like below. Named entity recognition with bidirection...
I guess there is no universal solution for that. But I can explain my roadmap as NLP scientist. Firstly, I try to find the most common dataset for my task (NER in your case). Then, I search for the leaderboard which shows the best papers/models for that dataset. Finally, I try to figure out which makes their models bes...
0
0
41
2021-07-25T15:50:27.410
data_quality
datascience.stackexchange.com
1,142,060
Changing KVM VM listening on 5901 to some other port
OK this is rather silly, but real problem. [CODE] keeps binding on 5902 port. That is because [CODE] is listening on 5900 and 5901: [CODE] I suspect this has to do with me setting display to VNC in VM configurations. Believe it or not, otherwise the keyboard in VM's console does not work (at least before actual OS boot...
This technology is called libvirt , and virt-manager you mentioned is just one of its clients. That's normal default behaviour. Let's look at the documentation : [CODE] ... [CODE] Starts a VNC server. The [CODE] attribute specifies the TCP port number (with -1 as legacy syntax indicating that it should be auto-allocate...
1
1
822
2023-08-21T12:27:02.200
infrastructure
serverfault.com
199,413
Database Mail works for one Instance but not three others
I have a test box with 4 Instances of SQL Server on it. One 2012 instance and three 2008 R2 instances. Database mail works fine on one of the named 2008 R2 Instances but not on any of the others. I've been going through the troubleshooting steps on Microsoft's website and everything checks out. All of the settings are ...
I'm not sure what the actually issue here was but after dropping the account and profile and re-creating them everything worked. Looking back, I realize that I had set it up on the first instance with the GUI, and then scripted it out and ran the script for the other instances. Why that didn't work I'm not sure. A big ...
1
1
494
2018-03-05T17:46:06.813
database_errors
dba.stackexchange.com
424,852
How to deal with massively concurrent events?
I got the following interview question: Say the company has this event, where we will create a button on a website and only the first ten clicks will be accepted and win a prize. Assume that there a millions of people around the world participating in this event. How would you implement it? My answer: Just save every c...
They are trying to get at your knowledge of distributed systems. One of the tenets of distributed systems is unreliable clocks. You cannot count on clocks being in sync on different nodes, and you cannot reliably measure how out of sync they are. There are algorithms to gain consensus on an order of events. One common ...
0
3
166
2021-03-27T15:09:17.740
api_errors
softwareengineering.stackexchange.com
901,491
Checking sudoers.d files with Ansible
I have an Ansible playbook I use to manage our sudoers files across our environment. We like to keep a minimal sudoers file at /etc/sudoers, then anything we want to add gets put into separate files under /etc/sudoers.d. My Ansible playbook contains the following task for pushing these files: [CODE] The task contains a...
I got it working. Here's what I did. First I added a set of Ansible tasks to create a staging directory at /etc/sudoers.stage.d and copy the contents of /etc/sudoers.d into it. I then upload the files to this staging area and, if any of them are changed, run a custom script to activate them. This is what the logic in t...
6
2
17,077
2018-03-13T18:57:33.953
pipeline_ops
serverfault.com
1,078,804
Hover.com domain cant be reached
I recently bought a .DE domain from Hover.com for use in email addresses (I am using mailbox.org) and also a web service in the future. The name-servers are set to ns1.hover.com and ns2.hover.com. I have 2 A-records set, one with '*' and one with '@' as host, pointing to hover.com 's IP address (64.98.145.30). These wh...
As you can see from whois: [CODE] The Status line is a concern. There is something wrong with your domain. The registry authoritative nameservers do not publish it, so the domain does not exist (does not resolve): [CODE] You need to go to your registrar (.de public whois does not show it), where you bought that domain,...
-1
1
461
2021-09-27T15:16:55.830
infrastructure
serverfault.com
932,191
Apache Rewrite not working
I have a very strange thing happening in my apache2 setup. I just want to redirect HTTP to HTTPS. I have tried all possible ways, like this: [CODE] I put this in [CODE] but it simply didn't work. I then put the above in [CODE] and it works, but I instead get This page isn’t working kanzan.se redirected you too many tim...
I put this in [CODE] but it simply didn't work. If by that you mean you put the directives directly in the server, in a server context, then the directives won't do anything if you have mod_rewrite directives in the [CODE] being accessed. You would need to enable mod_rewrite inheritance (but you may not want to do that...
1
2
165
2018-09-22T17:49:38.170
infrastructure
serverfault.com
20,626
What are the challenges with automation when using Selenium?
I recently had an interview question what problems did you have while testing in Selenium. Well, I have experience in Selenium, but maybe I was testing a simple application, but I dried up quickly. The problems are typical of any QA process, such as bugs would not go away even after developers fix the code. But what po...
There might be slight differences in behavior of different browsers (because they are written by different teams). Selenium tests can be flaky - fail, and later pass with no changes. As with many Open Source tools, documentation might less than perfect. Reference docs is there but examples might be scattered over blogs...
1
3
8,424
2016-07-21T02:00:16.647
data_quality
sqa.stackexchange.com
146,831
Informix Migrate Schema
I'm busy trying to migrate an informix database schema (with no data) to an informix database running on a different server. I have exported the schema from the database using [CODE] Then I am trying to import it into my new database [CODE] I am getting the error [CODE] Looking through informix forums they are saying t...
Never mind it seems dbimport won't work in this case because the schema wasn't generated with dbexport. It worked when I did [CODE]
1
1
324
2016-08-15T14:00:53.250
warehouse_errors
dba.stackexchange.com
35,959
Error when dropping InnoDB database
I am trying to drop a database in mysql, but every time I get this error [CODE] even logged in as root. Originally, I had a corrupted table that I could not recreate, hence I decided to recreate the db. I have innodb file per table, not sure if that matters. How can I drop this database?
I am afraid you cannot drop the database. The problem comes the table that is corrupt. It's not necessarily the [CODE] file. It is, more than likely, the data dictionary entry within ibdata1 ( See pictorial representation of ibdata1 ). I wrote about this back on [CODE] : InnoDB table SELECT returns ERROR 2006 (HY000): ...
9
10
23,388
2013-03-05T10:22:19.047
data_quality
dba.stackexchange.com
11,550
Peak memory usage of a process
Tools like top and ps can give me the amount of memory currently allocated to a process, but I am interested in measuring the maximum amount of memory allocated to a process either since its creation or in a given time interval. Any suggestions on how to find out?
You can get the peak memory usage of a certain process, at: [CODE] (Change $PID to the actual process id you're looking for). VmPeak is the maximum amount of memory the process has used since it was started. In order to track the memory usage of a process over time, you can use a tool called munin to track, and show yo...
16
27
26,552
2009-05-23T07:56:58.957
infrastructure
serverfault.com
122,800
lsnrctl is not working on Ubuntu 14.04
I have managed to install [CODE] on [CODE] through lots of pain. I managed to install it in the end but [CODE] does not seem to be working and even responding any command. My [CODE] is [CODE] My [CODE] file: [CODE] My [CODE] and [CODE] variables are working: [CODE] However, [CODE] commands does not respond at all: [COD...
Your lsnrctl has 0 bytes so either you didn't install Oracle software correctly or your installation is damaged. So reinstall Oracle software.
1
1
5,541
2015-12-03T14:28:32.913
warehouse_errors
dba.stackexchange.com
302,648
How can I group / display same date data in one row?
I have a table that gets inserted into every night that is a snapshot of the data. At any point in time, the data might change in the columns (AccountNo stays the same, RunKey is incremented by 1, and RunDate increments by 1 day; all other columns can change ad-hoc). Below is a sample of how the data looks: [CODE] Ther...
If I correctly understand this is what you're looking for: [CODE] AccountNo RunKey RunDate Item Value 12345 2 2017-06-20 Address,Salary,PromotionDate 123 Main Street,60000,2017-01-15 12345 3 2017-06-21 Address,Salary,PromotionDate 123 Main Street,60000,2017-01-15 12345 4 2017-06-22 Address,Salary,PromotionDate 123 Main...
0
0
834
2021-11-15T18:47:30.120
warehouse_errors
dba.stackexchange.com
278,180
php.ini use multiple include paths - openbasedir restriction
I need to allow an include path for a vhost subdomain on Plesk 10. I've edited the PHP PEAR path into /etc/php.ini as I'm happy for it to be globally available: [CODE] This works insofar as PHP is able to see the files in that directory when a script tries to include them, but I'm getting the dreaded openbasedir error:...
Ah found it! 1) create vhost.conf for the subdomain: /var/www/vhosts/xxxx.com/subdomains/test/conf/vhost.conf 2) add the following: [CODE] 3) Configure plesk to recognise new vhost.conf [CODE] 4) Restart apache [CODE]
1
1
3,433
2011-06-08T10:09:03.200
infrastructure
serverfault.com
418,284
FreePBX & Zoostorm
I'm having some issues trying to install the FreePBX Distro on a new Zoostorm box. It keeps asking me for drivers. Here's the error message: [CODE] I've tried switching the HD mode in the BIOS from AHcI to IDE, but this does not help. FreePBX Distro Stable-1.815.210.58 Zoostorm Manufacturer ID: 7873-1064 The motherboar...
The "FreePBX Distro" is unfortunately a poor choice for new hardware, since it's based on CentOS 5 and won't have support for many new motherboards. This particular error occurs because the kernel doesn't have driver support for various parts of the motherboard hardware. You would be best served by installing it yourse...
0
0
298
2012-08-16T15:30:39.527
infrastructure
serverfault.com
1,087,845
Reverse proxy in Apache + CentOS for HTTPS requests to PostgREST webserver
I would like to make https requests to my postgREST webserver, which by design doesn't support https. I spend several days now I don't know any further... My setup My server is running on CentOS 7.9.2009 I have a website domain that uses Wordpress to serve my content in [CODE] I setup PostgREST 7.0.1 on my server which...
Some things to check: Is SELinux running? If so is the SEBoolean [CODE] set to 1? Is [CODE] installed? Is anything on the non-proxied VirtualHost using the path [CODE] ? As in, would it block the calls to the [CODE] ? Better answer: How to handle relative urls correctly with a reverse proxy Not an apache expert, but th...
1
0
763
2021-12-20T22:29:25.590
infrastructure
serverfault.com
556,973
Modern DNS load-balancing solutions
I'm learning distributes systems and now I'm researching the DNS load-balancing topic. I have few Linux servers and I want to setup next configuration: one DNS load-balancer that resolves IP address of less loaded server; several application servers that process user requests and send own load statistics to DNS load-ba...
Most of the DNS based load balancing is not as much applied to clusters within a single data centre but more often used to point users to geographically nearby instances of an application. The problem with DNS is that records are cached, often longer then the TTL even, meaning that when you update the configuration of ...
1
3
5,155
2013-11-23T12:05:23.743
infrastructure
serverfault.com
161,557
Can I construct a trigger that deletes existing rows before inserting new ones in SQLite, which lacks FOR EACH STATEMENT?
Here’s my SQLite schema: [CODE] In words, the [CODE] table (a dependency tree) is intended to have multiple rows for each [CODE] pair—all rows with the same [CODE] pair are dependencies of [CODE] for some [CODE] . In my application, a user only batch -updates the dependencies of a target. By “batch” I mean that I would...
Remember that this is a lite version of SQL and does not support all operations. See the following link: https://www.sqlite.org/lang_createtrigger.html SQLite supports a BEFORE TRIGGER which can delete rows before further action is taken. The link also provides some cautions about how that works: If a BEFORE UPDATE or ...
0
2
1,376
2017-01-19T01:54:49.327
database_errors
dba.stackexchange.com
177,133
Tools, recommendations to understand NTFS permissions?
I'm trying to troubleshoot some issues with our IIS7 FTP site--namely, why some users have access to the site when it doesn't look like they should. The basic problem is that I do not understand NTFS / Active Directory permissions very well. Does anyone know if any tools exist that allow you to view where permissions a...
One tool that I find useful to see the state of permissions for a heircarchy is the sysinernals tool AccessEnum . It does not show you the permissions, instead it scans a folder and shows you who has read, write, or been denied access. Past that, go to a command line and use the icacls command to examine a folder or fi...
1
1
566
2010-09-01T21:04:50.137
infrastructure
serverfault.com
1,106,516
Google Cloud SSH suddenly having network problems
I was about to upload something and restart some apps on my VM, I got to the phase of Transfering SSH keys, and after that, I got the following error: Connection [CODE] When I click "Troubleshoot", VM Status is OK My other VM instance on another project is working. I haven't changed anything in VM or project configurat...
Use the SSH troubleshooting tool to help determine why an SSH connection failed. The troubleshooting tool performs the following tests to check for the cause of failed SSH connections: User permissions tests: Checks if you have the required IAM permissions to connect to the VM using SSH. Network connectivity tests: Che...
0
1
1,318
2022-07-25T10:46:53.380
infrastructure
serverfault.com
594,691
IIS 8.0 Second Website on port 81 not visible publicly
I have been given a VM in Windows Azure with Windows Server 2008 R2/ IIS 8.0 running. It has a default website. Now I wanted to create a dev version of that site at some other port, say 81. I added that application and added inbound rule in the firewall for tcp port 81. Now I can browse the site on that machine using [...
There are 2 things you have to do for this to work on a VM on Azure. Windows Firewall Make sure you have a firewall rule that allows connection over TCP to port 81. It should look like this Azure Firewall In Azure portal, go to your VM. Then click on the endpoints tab and add a rule for port 81 as well it should look l...
1
2
5,860
2014-05-13T07:08:01.530
infrastructure
serverfault.com
879,176
How to configure SELinux for nginx to access a symlink to a mounted directory
I have a libvirt vm running nginx with a shared filesystem mounted in the nginx vm, and I want to expose a directory in that mount. nginx seems to be running fine, and I can access the basic local files and subdirs in /usr/share/nginx/html. I have a symlink from the mount to the default nginx location, via [CODE] ..and...
I eventually stumbled on the following as a solution: [CODE] Thanks to @bell for the tips on troubleshooting, I definitely will be referencing them for future issues!
0
1
2,932
2017-10-18T22:02:44.680
api_errors
serverfault.com
711,026
How to take backup of a table on a different schema in PostgreSQL
Please let us know in PostgreSQL how we can take backup of a table on a different schema. We have db named "geopostgrest" and under Schema named "1" (Not inside Public Schema) we need to take backup of table "activity" Please see the following: [CODE] We tried the following command but its not working. [CODE] We are us...
Able to take backup of a table on a different schema in PostgreSQL with the following command and its working perfectly: [CODE]
1
1
2,391
2015-08-05T13:07:54.430
database_errors
serverfault.com
127,735
enabling slow_query without general_log
I have been playing a bit to enable slow_query_log, i never got any results until i enabled the general_log (1), but i also get logged ALL the queries, which i do not need, and it causes a performance problem. Is there a way to get ONLY slow queries logged? [CODE]
To get the slowlog to show more, lower [CODE] (in my.cnf) to 1 (second) or even less. Don't turn on the general log. Hopefully future versions of MySQL will have a default of something less than the virtually useless "10". Consider using [CODE] to summarize the slowlog after it has collected some data.
0
1
139
2016-01-29T15:09:50.870
warehouse_errors
dba.stackexchange.com
151,394
How to deal with seldom used big database and postgresql?
I loaded in PostgreSQL (9.3) OpenStreetMap data for whole europe (400gb). Then I installed a geocoding api (nominatim) that queries the database with gis queries. My problem is : This database is queried a few times a day, but because postgres loads the data in its buffer on demand, my first query on a particular gps p...
depending on your usage, you could try to partition the data to reduce the scanned data (at 400gb even your indexes are large and heavy to read...) I think it's your best option as working with 400gb tables is heavy even on a very optimized queries... You could also pre-warm the cache with the index data , by issuing s...
3
0
420
2016-10-04T12:31:27.190
database_errors
dba.stackexchange.com
213,577
Rich Domain Models -- how, exactly, does behavior fit in?
In the debate of Rich vs. Anemic domain models, the internet is full of philosophical advice but short on authoritative examples. The objective of this question is to find definitive guidelines and concrete examples of proper Domain-Driven Design models. (Ideally in C#.) For a real-world example, this implementation of...
The most helpful answer was given by Alexey Zimarev and got at least 7 upvotes before a moderator moved it into a comment below my original question.... His answer: I would recommend you to watch Jimmy Bogard's NDC 2012 session "Crafting Wicked Domain Models" on Vimeo. He explains what rich domain should be and how to ...
98
72
30,426
2013-10-06T18:49:29.267
hadoop_errors
softwareengineering.stackexchange.com
106,860
IE8 doesn't accept a valid certificate while Firefox does
When I browse my site with IE8, it gives the error below. [CODE] But when I use Firefox, it says it's verified by GoDaddy.com, Inc. I installed [CODE] to IE8 but the problem persists. Do you have any ideas for that? Thanks!
I downloaded all certificates from Go Daddy Repository and installed [CODE] , now it it seems ok.
1
0
9,323
2010-01-27T16:18:46.667
infrastructure
serverfault.com
77,927
How to access the data of the column on which some groupby operation has been carried out?
Suppose there is a pandas dataframe which has one column consisting of names of something, and there are multiple entries respective to each entry in the first column. To count the number of entries in the second column for each entry in the first, applying count method grouped by entries on the first is the classical ...
As [CODE] is not a key when you make the new dataframe so you can't access it. So you just need to reset index so that [CODE] can be accessed when required. [CODE]
1
0
77
2020-07-18T18:44:11.750
data_quality
datascience.stackexchange.com
289,569
Slow SQL taking almost 1s to execute with only 24000 records! (EXPLAIN included)
Any ideas how to improve and what the actual culprit is? records in product are only 24000 takes 0.85s to run Mysql 5.7 [CODE] The explain: [CODE] As requested the SHOW CREATE TABLEs: [CODE]
[CODE] almost always means that you should add a composite index. [CODE] needs [CODE] That index will help some, but probably not a lot. The [CODE] cannot be optimized, nor helped by an index. So must find all the possible rows, sort them, then finally deliver the first 15. Shrinking the [CODE] to realistic limits migh...
0
2
55
2021-04-09T19:01:13.467
database_errors
dba.stackexchange.com
1,081,484
load balancing over single NIC to overcome per-connection limit
I have a strange setup where the ISP provides a very fast connection (10 Gbps) but limits each connection to 50 Mbps. This is fine for multi-threaded applications where I can just boost the number of threads. But I would like to solve this problem for single-threaded applications as well. I am running Linux and this is...
I don't think there's a point. Of course, you can use multiple source IPs (whether from multiple hosts, multiple NICs or even a single NIC) but then again, you'd likely NAT all of those to the public IPv4 address you've got - so there's no difference from the outside. You can just as well just use multiple threads. But...
2
2
242
2021-10-23T12:06:22.083
infrastructure
serverfault.com
157,899
Log compression without indefinitely long lag?
A common situation is that a program or another writes logging information to stdout, and due to its volume I pipe it through gzip on its way to disk. Unfortunately gzip and most compression programs like it don't feel obligated to ever flush their output - and if the program freezes, even if it printed a lot of highly...
As there was no ready to use program for it, I wrote one myself .
1
0
534
2010-07-06T17:04:58.300
infrastructure
serverfault.com
1,031,939
How to configure NFS to resolve symbolic links on the server side?
My beard is solid grey now, and I long recall using NFS for all these decades and here I cite the original RFC that gives us the basis for the NFS we have today RFC1094 . Of course, three decades and some have passed since then, so here's the question: In the interim has it become possible now, via a configuration opti...
The symlinks are always resolved by the client. There are several reasons for that. First of all, the NFS protocol has a concept of a file handle. Each handle points to a file system object that can be a directory, a file or a symlink (and some others). Moreover, NFSv4.1 spec is clearly says: Whether created by an NFS ...
6
4
12,856
2020-08-29T03:42:09.973
infrastructure
serverfault.com
915,931
OpenVPN client on OpenWRT not routing traffic through VPN on Linksys WRT3200ACM
I am unable to get the traffic routed through the VPN tunnel, when using OpenVPN on OpenWRT firmware. The router is a WRT3200ACM, connecting to OpenVPN server on Ubuntu. OpenVPN client is connecting and I am able to ping ip's on the the remote network from SSH console on the router. However, all my connectet clients on...
I think in your case this is a routing issue. You state that the configuration works well on your clients - hence your clients get an IP-Addr within the [CODE] range and route all traffic via the Ubuntu. The sending IP here is a [CODE] IP. Furthermore, the ping works with SSH from your local router when connected, but ...
1
0
2,739
2018-06-09T20:57:44.500
infrastructure
serverfault.com
118,106
Monitor Process
I have some previous posts talking about how to use python to "do something" when a record is inserted or deleted into a postgres database. I finally decided on going with a message queue to handle the "jobs"(beanstalkd). I have everything setup and running with another python process that watches the queue and "does s...
You can [CODE] for beanstalkd's pid; if it exits (cleanly or otherwise), [CODE] will return you the exit code, and you will be able to restart the process imemdiately. Beanstalkd persists its queue (if you specity [CODE] ), so beanstalkd process crashing time to time (if ever) probably is not an issue. But your postgre...
4
2
1,398
2011-11-06T03:25:48.883
pipeline_ops
softwareengineering.stackexchange.com
274,828
Could not resize shared memory segment error
I have a PostgreSQL 11.2 (Debian 11.2-1.pgdg90+1) running in a docker container. I get the following error with some queries: could not resize shared memory segment "/PostgreSQL.860708388" to 536870912 bytes: No space left on device` system: Ubuntu 18.04.5 memory: 126 GB cores: 64 disk usage is fine, as well as quotas....
Lowering number on [CODE] to 8 seems to have fixed the problem in my case.
1
1
4,261
2020-09-02T09:16:32.487
database_errors
dba.stackexchange.com
23,364
Solutions to problems that .NET can solve better than Java (or vice-versa)
To me it seems these are two different platforms that address similar enterprise(but not only) problems. I'm interested however in problems that Java can solve better than C#/.NET or C#/.NET can solve better than Java. Leaving aside the 'cost' factor, since that is somehow not an issue for big enterprise companies (the...
There are some language features in C# (4/5) such as LINQ, [CODE] predicate and some functional aspects that many would argue place it ahead of Java 6 in terms of productivity/flexibility (YMMV on that). Others would argue that C# is becoming a big cesspit of every brand new idea that happens to be popular and it's get...
5
8
858
2010-12-03T11:28:43.443
api_errors
softwareengineering.stackexchange.com
78,892
Can you put a SQL DB on a NAS?
Can you put a SQL DB on a NAS drive? For example can I put the PostgreSQL DB "files" on a Sinology NAS or am I better to leave everything on a "real" PC? (like, say, a regular PC server running Linux) I'm asking this question because something weird happened: some accounting app written in WinDev (a RAD tool kinda famo...
Databases require certain guarantees from the storage it runs on to implement ACID. Unfortunately, it is not always possible for the database to determine if those guarantees are met. Here are some requirements that the storage (no matter if it is NAS, direct attached or SAN) must meet: Write Ordering : Writes my happe...
2
5
11,184
2014-10-10T14:30:12.417
database_errors
dba.stackexchange.com
712,849
How to unlock an SSD disk with hdparm?
I have an SSD disk with password protection, but the password was lost long time ago... so I tried to erase the ATA security with the [CODE] command. With "hdparm -I", the disk information looks interesting as below: [CODE] As you can see, the disk is in the security locked state, and it doesn't support [CODE] security...
I was able to get this to work on my Western Digital WD20EURS. After piecing together tips from all over Google, I was able to get a master password, research the commands of [CODE] , and use your example in your original question to resolve my issue. Maybe this will help you too. First off, I found a list of master pa...
20
18
126,374
2015-08-09T06:15:44.110
infrastructure
serverfault.com
952,863
Can you use m5d's local SSD as a root device?
I've been using the Amazon ECS AMI on m5 EC2 instances, and I noticed that there's a new m5d instance type which is similar but comes with a 70 GB local SSD. Since these are throwaway instances, faster semi-cheap SSD's seem perfect, but I can't figure out how to actually use this local storage. I initially tried to rep...
You can't use the Instance storage as your root device . That used to be possible many years ago but as far as I know it's no longer supported with new AMIs. So your root will have to be on EBS and you will have to format and mount the ephemeral device during boot and use it only for your temporary data, cache folders,...
4
8
1,513
2019-02-07T21:40:36.743
infrastructure
serverfault.com
287,421
Efficient way to handle foreign keys
I am building a script that checks a large network of sites for invalid links. The idea is to flag links that continuously show as not available so that they can be cleaned by the administration team. The basic process is this: Grab a set of pages - approximately 30K per day, not the same 30K each day - and extract all...
looking up the LinkID at each insert seems inefficient You never tested it, I assume? Sounds like a typical case of premature optimization. Using proper indexing, especially for the URLs, should make a query for an URL roughly as fast as an INSERT into the same table (maybe the INSERT will become a little bit slower si...
1
2
137
2015-06-21T04:40:17.667
data_quality
softwareengineering.stackexchange.com
244,849
History of cluster failover
Is it possible to get a history of when a cluster failed over and which node became the active node?
Is it possible to get a history of when a cluster failed over and which node became the active node? That depends on how your define "history". There will be, in the cluster log, system log, and potentially sprinkled in other logs depending on a few things, the events that show a failover has occurred. For example, in ...
3
7
2,888
2019-08-08T09:56:46.333
database_errors
dba.stackexchange.com
215,246
Server Performance
We have a dedicated server that we use to stage websites (our test server). The performance of the server has become really bad and we regularly have to restart it. When performance is poor I have checked task manager for the processes and memory but everything looks OK. We use a content management system and it is alw...
Does this sound viable? Yes. Any other sggestions of how I can go about testing this? Performance check. Note that performance is not CPU only. If you think the db isthe issue, it may be IO bound - disc latency / activity percetnage will skyrocket in this case. Check disc performance counters. Especially if you are IO ...
3
5
500
2010-12-22T11:16:32.017
infrastructure
serverfault.com
374,410
How to make VirtualMachines under Ubuntu accessible to every user?
I have a WinXP virtual machine under Ubuntu and every user on this Ubuntu should have permission to run this VM. But every time someone runs this VM, the file permissions are set [CODE] and [CODE] (accordingly [CODE] and [CODE] ) and ownership is set to the last user. Then i change them back to [CODE] and [CODE] , so a...
Access mode (permissions) can be changed by file owner and by root , right? Thus [CODE] on the files are supposed to lock out everyone but root from mangling with access modes - unless the files are recreated every time, which needs write access to the containing directory, which is not as safe to take away but worths ...
2
2
934
2012-03-28T14:08:00.810
infrastructure
serverfault.com
283,151
Error 1242(21000) after creating following trigger and performing delete operation
I want to create a trigger which copies the record from maintable to undostack before deleting it in maintable and undostack table acts a stack of 5 records space and this trigger performs a push operation. This is my trigger [CODE] When undostack is not full [CODE] When undostack is full and has to delete the oldest r...
The easiest way to do this, is(for example undo_no 1) [CODE] By using [CODE] Mysql generates a table which it uses to select your data. usully i would say make this better in your pplication code, but five rows is very samll
0
0
155
2021-01-13T13:24:33.043
database_errors
dba.stackexchange.com
149,625
Volume size doesn't match Disk size after gparted expansion
I just expanded a basic disk on a Windows XP VM from 15gb to 40 gb using GPARTED LiveCD (0.5.2-11). I didn't notice anything unusual during the expansion; but after I rebooted back into Windows, the disk capacity doesn't match the disk size as it should (only 1 volume on the disk). The disk shows as 40gb; but the C: vo...
You may need to use diskpart to tell XP to grow the filesystem. This KB article goes through the process.
1
1
1,967
2010-06-09T13:14:57.350
infrastructure
serverfault.com
176,040
List chronological pageviews without adjacent duplicates in PostgreSQL
I've got a log of pageviews. Multiple pageviews with the same path may occur next to each other if say the user refreshes the page. To see the user's journey through the site I'd like to select pageviews for that user but eliminating duplicate adjacent pageviews for clarity. Example simplified table (time is really a t...
[CODE] First what you need to do is create something you can group by, for this we compute [CODE] . For more information about why it's in a [CODE] , see this question In what case is a count(x or null) needed in Gaps and Islands? [CODE] Then we count them to create groups. [CODE] Now we group by the user_id, and grp. ...
4
1
167
2017-06-12T11:37:21.793
database_errors
dba.stackexchange.com
996,717
Debian add a new PAM module and require it even if password authentication is failed?
I have these lines in [CODE] : [CODE] Now I installed google-authenticator and appended [CODE] to the end of that file. Now it works, but if I entered a incorrect password, the authentication will fail immediately, without asking for OTP. What I want is that if either one entered is incorrect, the system still prompt f...
You probably have in your [CODE] the following lines: [CODE] In case of password failure in pam_unix , PAM will go to the next line, which is an unconditional failure and is requisite so the authentication stops here. In case of correct authentication the second line will be skipped. You probably want to replace the [C...
1
2
1,530
2019-12-25T05:43:14.673
api_errors
serverfault.com
1,146,845
Amavis outbound mail filter for Postfix?
Running Postfix on Ubuntu 22.04, I'd like to make sure all outgoing mail originating from the server (eg mail forms on websites and stuff) is filtered for spam and malware. I'm using Amavis, which is filtering inbound, but not outbound. For example, if I try to send an EICAR test out like this: [CODE] I see this in the...
Postfix treats mail differently when it doesn't arrive over smtp, for example when it is directly submitted with the [CODE] command. Unfortunately: that is typically the default method many mail forms and libraries use to send mail and also what [CODE] uses by default. You can add milters/filters to mail that is sent v...
0
0
98
2023-10-30T09:07:42.563
infrastructure
serverfault.com
205,114
storing "replaced" records
We are storing assets in an asset table, using auto Increment to assign an ID to an asset. I have been asked what happens when an asset is replaced eg, water heater leaked, replaced with a new one. I suggested that in the interface a button to replace the item, would create a new row, with some of the details copying o...
You could add one more field in your table, something like parent_id where you could store the primary key from which the new record is derived. And primary key will continue to auto-increment. I hope this will fix your confusion.
0
0
27
2018-04-27T01:54:09.667
warehouse_errors
dba.stackexchange.com
217,959
what are memory fractions and how to get rid of them (or the sort operator) in the example below?
This execution plan has the following memory fractions: [CODE] it is a very simple query: [CODE] what are memory fractions and how to get rid of them (or the sort operator) in the above example?
Having a look at the properties of the sort operator: it has MemoryFractions Input="1" Output="1" getting rid of this sort operation having a look at the indexes and definition of table [CODE] there are no [CODE] only the primary key [CODE] same with table [CODE] [CODE] I create the following indexes (paying attention ...
5
5
706
2018-09-18T17:18:27.320
database_errors
dba.stackexchange.com
1,141,756
Hp proliant Dl380p gen 8 power issue
Hi my hp proliant dl380p gen 8 sometimes lunches into the hp loading screen then shuts off other times it doesn't get to loading screen and just try's to start up you can hear it and see it send power thru the system but shuts off the health light is blinking red [CODE]
Make sure your RAID setup is done and correct. You have 0 logical drive and an error as the array is not configured. If you had a OS prior, it mean your RAID setup was flushed or new drive was inserted that wasnt part of a RAID before hand. If so restore a backup and recreate your array. I ask as I seen that error; whi...
1
2
161
2023-08-17T00:53:16.617
infrastructure
serverfault.com
1,006,330
Issue with configuring php-fpm mod proxy on centos 6
I'm configuring PHP_FPM on a Centos 6 distribution. I'm using php 5.4.45 and apache 2.2.15 and the "mod_proxy.so" to call the socket. But with the following Vhost and php-fpm configuration I still get the same two issues in my site logs : [CODE] I'have tried and read a huge amount of solutions but no one of them helped...
Apache 2.2 natively does not have [CODE] (cf. this question ), you must have obtained it from alternative sources . Moreover using [CODE] with the [CODE] directive works from version 2.4.10 . Therefore: Your [CODE] block has no effect, so you can delete it, Only your [CODE] directive is working. However your version of...
0
0
563
2020-03-10T10:55:57.403
infrastructure
serverfault.com
448,763
Shell Script Design Patteren: Source a library file VS Call different files?
We discuss about POSIX compliant shell script here. While we are writing more and more shell scripts, we build some helper functions to reuse the codes. We are considering putting a few helper functions (around 10 functions of the same category) into a library file (e.g. [CODE] ) or splitting each functions into indivi...
First piece of advice is to echo Stefano Borini: "don't." Some languages offer good support for core software engineering concepts without the need of supporting 1970's [CODE] syntax. Prefer python over bash wherever you can, or similar high level languages. Ok, we're writing some shell scripts. Do yourself a favor, an...
3
6
103
2023-11-21T17:38:15.583
api_errors
softwareengineering.stackexchange.com
991,821
Subsequent calls to WMIC return a localdatetime with a deviating timezone
The problem In our company environment we use several batch files which use WMIC to retrieve the current time. Usually to print it to log files, but also to include the timestamp in a file name. Starting with Windows 10 - we do not remember seeing this behavior on Windows 7 - we experienced that some of our log file pa...
That is now a known Windows Bug. Internally there is a global variable which caches the DST offset which keeps its value for 5 minutes. After 5 minutes the value goes away which leaves you with a jumping local time. This logic was being used in RS5/1809 but not in 19H1 or in Windows Server 2012 R2. Workarounds: Boot th...
3
2
2,709
2019-11-14T12:42:20.330
infrastructure
serverfault.com
605,803
ssh shared key authentication asks for password, unless sshd runs with -d option
My client is Ubuntu, and the server is CentOS. I have shared key authentication set up to login from client to server. When I run the server like: [CODE] Everything works as expected; I don't get a user login prompt. I take this to mean that everything is in the correct place, with correct permissions, etc. When I rest...
TLDR; SELinux I went back to using the same user account on both machines. More importantly, this means I am using home directories that SELinux is on-board with. You can see in the logs that the "web" user has non-standard home directory [CODE] (it is intended to be the web content mgmt account) I then removed the [CO...
2
2
935
2014-06-17T16:23:43.507
api_errors
serverfault.com
793,123
How do I mount a home catalog using cifs and autofs with Active Directory authentication on CentOS7?
I'm trying to integrate a CentOS7 client with Active Directy authentication and automatically mounting the user homedirs with cifs. I would prefer to use autofs, but I've so far been unable to make cifs mount work with sec=krb5 setting. It always fails with this message [CODE] Any hints on getting autofs to work with c...
I do have a workaround using pam_exec, but do not feel that mounting of file shares belongs in the pam framework. By inserting the following lines into /etc/pam.d/password-auth the listed script at the end will mount the right homedir upon password authentication. A lazy unmount is performed at session_close, but might...
1
0
1,206
2016-08-01T11:20:25.000
api_errors
serverfault.com
157,647
How to prevent duplicate VARCHAR without a key limit?
I'd like to store URLs in a database column, and enforce a constraint that values must be unique. Unfortunately, MySQL has a limit on the length of index keys which means that only the first X characters of the URL gets checked for uniqueness. Thus, I've run into false positives where two different URLs triggered a con...
Answering my own question (since all other answers used a hash column or placed a limit on the column length): [CODE] Recap: Create a non-UNIQUE index on the column containing the URL ("value" in the above code) Use the longest-possible index key (191 in my case, because I am using [CODE] encoding) Add a [CODE] trigger...
4
1
4,390
2016-12-09T02:02:46.797
data_quality
dba.stackexchange.com
439,668
Is going through network during DI anti pattern?
So I want to inject an Application Client, say a Rest Api client, in my code. In order to create this client I need to go over the network to get it's user and password that is in a HTTP Vault. This behavior got my team divided, some saying it's an anti-pattern to go to the network before finishing injection, some othe...
"during DI" is the sticking point here. I can point you to numerous references 1 , 2 , 3 that argue that constructors should not do "real work" (and others 4 , 5 that argue that it's fine). That is, they should stick to validation and initializing state. But "during DI" can be taken to mean more than simply stuff const...
0
7
229
2022-07-06T15:06:15.060
api_errors
softwareengineering.stackexchange.com
445,055
How to avoide too many dependencies when flow use many call to external vendor
I'm trying to design mediator micro-service which will have around 20-30 different http requests to an external vendor. My general high level thoughs are on creating a BaseService class which will implement the Template Method pattern where each inherited class will be responsible on specific call, with its own request...
It is possible that the Template pattern might be a good fit. I tend to find it overly abstract when trying to debug code that uses that pattern (even code I wrote within the last week). My preference when building a service API is to use the Command pattern. Each call to the service's public API calls a specific comma...
0
0
94
2023-04-15T17:34:38.060
data_quality
softwareengineering.stackexchange.com
123,156
Restoring an Oracle database from files
I am running into a problem now, i have an oracle database that is stored inside a server and now because of the sudden blackout the c drive is messed up. The drive is partitioned, windows on c and oracle on drive e. The oracle installation folder is fine on E:\app. Now i have to restore that database on the another se...
First off, you would want to install a new instance somewhere—possibly on the same host. Then you would need to mount the control file (the path to the control file can be specified by setting the [CODE] parameter value in pfile). Once you've mounted the control file with [CODE] , you can use RMAN to identify the data ...
1
2
103
2015-12-07T14:37:22.313
database_errors
dba.stackexchange.com
61,357
Can't update trigger because of activity
Trying to add a line to a trigger that is attached to a table that is constantly in use [CODE] Getting deadlocked and the only solution appears to be retrying every couple of seconds, which so far hasn't worked. Is there any other way to get my if condition in other than hitting F5 and hoping it works? Thanks, Craig
When you issue an [CODE] statement, that process will attempt to acquire a SCH-M (schema modification) lock on the table object as well as the trigger object. This is an extremely low-concurrency lock and will cause the expected blocking that you're running into. See this reference for a chart on lock compatibility. Fo...
5
7
1,986
2014-03-20T14:41:42.350
database_errors
dba.stackexchange.com
107,673
Are there any implementations of non Naive Bayes Classifier in Python?
Naive Bayes assumes that predictors are independent. Though this assumption is quite powerful, in some scenarios it fails miserably . So are there any implementations of non Naive Bayes in Python ? Are there any issues that prohibit implementing non Naive Bayes Classifier.
A non-naive Bayes classifier is doable if one knows which specific features depend on each other, or if there are very few features. In any other case, the exponential number of dependencies requires an extremely large volume of instances in order for the classifier not to overfit. The independence assumption in Naive ...
2
1
260
2022-01-31T09:57:09.323
data_quality
datascience.stackexchange.com
912,326
Restrict access to an SVN repo to members of one group
I have a few dozen SVN repos that must be accessible to all users, and a single repo that needs to be restricted to just one group. I've tried setting up my .svnaccess file like so: [CODE] However, this results in even alice and bob being unable to access RestrictedRepo. If I use [CODE] instead of [CODE] , then I end u...
My problem was that the apache config contained these lines: [CODE] This allows unauthenticated access to the server for all read operations. It appears I will need to either require login for all reads (by removing the LimitExcept specifier around the Require) or implement something like what's described at http://svn...
0
0
1,535
2018-05-15T13:47:35.830
infrastructure
serverfault.com
675,257
Route 53 subdomains and their redirects
I am having problems with my redirects. I have a bucket named example.com created in s3 which redirects to http://google.com (just an example). In route 53 I am able to point my example.com domain to example.com.s3-website-eu-west-1.amazonaws.com and that works. Now I want to redirect my www.example.com subdomain to th...
Is this possible or do I have to create www.example.com bucket which redirects to same page as example.com bucket? Yes, you'll need to create a second bucket for the [CODE] version. To keep things a little simpler, you can redirect the [CODE] to [CODE] and let the main bucket handle the final redirect.
-1
1
112
2015-03-13T12:49:06.423
infrastructure
serverfault.com
154,637
Problem getting SQL Server 2016 R Services (In-Database) working
SQL Server 2016 CU2 (Enterprise) here and one of my users has requested that we get R-Services installed. I followed what appeared to be very simple instructions from this page Set up SQL Server R Services (In-Database) When I got to the part about using the simple test [CODE] it failed with Msg 39021, Level 16, State ...
We wound up having to copy two folders (MSSQLSERVER01 and MSSQLSERVER02) from our Sql Server install directory, which for us was located here [CODE] We copied the above folders to the new WORKING_DIRECTORY (C:\TEMP\R_SERVICES) we had specified in the rlauncher.config file. After that, we were able to run the sample R_S...
2
2
5,422
2016-11-08T19:49:48.460
database_errors
dba.stackexchange.com
627,704
tcp ack delay almost 600ms, is this all right?
As far as I konw, tcp delay ack always 200ms, but now in my production environment it delay almost 600ms, my environment is below: ubuntu 11.04 48G memory 16 core, load not heavy; I catch packet in the server(6380 is server port), the packet is below, as we can see at time 16:29:24.036999 the server receive a packet fr...
RFC 1122 section 4.2.3.2 specifies that an ACK can be delayed as much as 500 milliseconds: [CODE] There is no rush to send an ACK. Something is odd here though, the retransmission seems awfully quick.
2
1
1,918
2014-09-11T00:48:22.680
api_errors
serverfault.com
91,331
Trying to avoid bad MySQL database design - can't figure out how to avoid too many columns
I am pretty much a beginner having only created a few small php web applications relying on a MySQL database. I am now working on a somewhat larger project. I am in the planning stages of setting up the database and am having difficulty wrapping my mind around one issue. The database will be used for Lego. The main tab...
Anytime you'd start getting a col1, col2, col3 in a database design, you "typically" want to consider those columns as rows in another table. (typically, there are always exceptions - doubtful this is the case ;) ) So you have a LEGO_SETs and LEGO_PARTs table already ? Sounds like you have something like this: [CODE] Y...
0
1
114
2015-02-06T18:16:40.110
database_errors
dba.stackexchange.com
255,838
Slow SQL Queries
I'm having problems with my application performance. The tables in the database have the following records: "issues" has more than 334823 "custom_values​​" has over 1350243 "users" has 1350 "projects" 494 The system currently has 1350 users. Currently only goes to 100 concurrent users. The application is being way too ...
These defy optimization: [CODE] , [CODE] , [CODE] . See if you can reformulate the query to avoid some of those. The only hope I see is in [CODE] -- Can you turn that into a [CODE] search? [CODE] is avoidable via using a case-insensitive collation. (We can't see the collation for [CODE] .)
0
1
65
2019-12-18T04:09:31.270
warehouse_errors
dba.stackexchange.com
717,228
Could HAProxy disable the Apache Instance on the same node it is running?
I have a setup with three VMs that are running on a core i74xx. The machines form a LAMP cluster with HAProxy doing the loadbalancing. After running multiple load tests I found out, that throughput doubles as soon as I put the Apache Instance running on the same node as HAProxy into maintenance mode - Therefore giving ...
If each node has it's own HAProxy config you have several options: each haproxy can ignore local backend use "weight" parameter to lower percentage of traffic that ends on local backend
1
0
450
2015-08-27T12:42:02.763
database_errors
serverfault.com
89,376
Regression with LSTM network: use multiple time series as input
I've spent a few days on this and am starting to think I'm missing the obvious solution as this doesn't seem like a very uncommon problem. As an example dataset: I have 100 measurements with each a different constant speed as target and a length of 10000 data points. Every measurement has additional 30 features that ar...
I think what you're looking for is to change your dataset into a supervised learning problem. Keras has its own TimeSeriesGenerator but that wont be of use as it only has a single step output. Someone created an alternate version of the TimeSeriesGenerator . Using this, you can specify the inputs and outputs per sample...
0
0
534
2021-02-15T00:13:51.953
airflow_errors
datascience.stackexchange.com