Daily Archives

Articles indexed Monday October 21 2013

Page 13/18 | < Previous Page | 9 10 11 12 13 14 15 16 17 18  | Next Page >

  • Double pointer as Objective-C block parameter

    - by George WS
    Is it possible (and if so, safe) to create/use a block which takes a double pointer as an argument? For instance: - (void)methodWithBlock:(void (^)(NSError **error))block; Additional context, research, and questions: I'm using ARC. When I declare the method above and attempt to call it, XCode autocompletes my method invocation as follows: [self methodWithBlock:^(NSError *__autoreleasing *error) {}]; What does __autoreleasing mean here and why is it being added? I presume it has something to do with ARC. If this is possible and safe, can the pointer still be dereferenced in the block as it would be anywhere else? In general, what are the important differences between doing what I'm describing, and simply passing a double pointer as a method parameter (e.g. - (void)methodWithDoublePointer:(NSError **)error;)? What special considerations, if any, should be taken into account (again assuming this is possible at all)?

    Read the article

  • Would vector of vectors be contiguous?

    - by user1150989
    I need to allocate a vector of rows where row contains a vector of rows. I know that a vector would be contiguous. I wanted to know whether a vector of vectors would also be contiguous. Example code is given below vector<long> firstRow; firstRow.push_back(0); firstRow.push_back(1); vector<long> secondRow; secondRow.push_back(0); secondRow.push_back(1); vector< vector < long> > data; data.push_back(firstRow); data.push_back(secondRow); Would the sequence in memory be 0 1 0 1?

    Read the article

  • Exploiting Path Traversal Vulnerability

    - by Maputo
    I have a Java Web App running on Tomcat on which I'm supposed to exploit Path traversal vulnerability. There is a section (in the App) at which I can upload a .zip file, which gets extracted in the server's /tmp directory. The content of the .zip file is not being checked, so basically I could put anything in it. I tried putting a .jsp file in it and it extracts perfectly. My problem is that I don't know how to reach this file as a "normal" user from browser. I tried entering ../../../tmp/somepage.jsp in the address bar, but Tomcat just strips the ../ and gives me http://localhost:8080/tmp/ resource not available. Ideal would be if I could somehow rename the somepage.jsp so that it gets extracted in the web directory of the Web App. But then, the Linux filesystem disallows slashes in filenames (e.g. ../../home/webapp/somepage.jsp). Are there maybe any escape sequences that would translate to / after extracting? Any ideas would be highly appreciated. Note: This is a school project in a Security course where I'm supposed to locate vulnerabilities and correct them. Not trying to harm anyone...

    Read the article

  • fortran error I/O

    - by jpcgandre
    I get this error when compiling: forrtl: severe (256): unformatted I/O to unit open for formatted transfers, unit 27, file C:\Abaqus_JOBS\w.txt The error occurs in the beginning of the analysis. At the start, the file w.txt is created but is empty. The error may be related to the fact that I want to read from an empty file. My code is: OPEN(27, FILE = "C:/Abaqus_JOBS/w.txt", status = "UNKNOWN") READ(27, *, iostat=stat) w IF (stat .NE. 0) CALL del_file(27, stat) SUBROUTINE del_file(uFile, stat) IMPLICIT NONE INTEGER uFile, stat C If the unit is not open, stat will be non-zero CLOSE(unit=uFile, status='delete', iostat=stat) END SUBROUTINE Ref: Close multiple files If you agree with my opion about the cause of the error, is there a way to solve it? Thanks

    Read the article

  • InputVerifier don't display each component icon(lable)

    - by Sajjad
    I have a form that set a input verifier to it. I want when a user type a correct value for a text field and want to go to other text field, a check icon should be display besides of text field. But now in my code, when user type a correct value on first text field an go to other, Two icons displayed together! public class UserDialog extends JDialog { JButton cancelBtn, okBtn; JTextField fNameTf, lNameTf; JRadioButton maleRb, femaleRb; ButtonGroup group; JLabel fNameLbl, fNamePicLbl, lNameLbl, lNamePicLbl, genderLbl, tempBtn, temp3; public UserDialog() { add(createForm(), BorderLayout.CENTER); setDefaultCloseOperation(DISPOSE_ON_CLOSE); setLocation(400, 100); pack(); setVisible(true); } public JPanel createForm() { JPanel panel = new JPanel(); ImageIcon image = new ImageIcon("Check.png"); okBtn = new JButton("Ok"); cancelBtn = new JButton("Cancel"); tempBtn = new JLabel(); fNameLbl = new JLabel("First Name"); fNamePicLbl = new JLabel(image); fNamePicLbl.setVisible(false); lNameLbl = new JLabel("Last Name"); lNamePicLbl = new JLabel(image); lNamePicLbl.setVisible(false); genderLbl = new JLabel("Gender"); maleRb = new JRadioButton("Male"); femaleRb = new JRadioButton("Female"); temp3 = new JLabel(); group = new ButtonGroup(); group.add(maleRb); group.add(femaleRb); fNameTf = new JTextField(10); fNameTf.setName("FnTF"); fNameTf.setInputVerifier(new MyVerifier(new JComponent[]{maleRb, femaleRb, okBtn})); lNameTf = new JTextField(10); lNameTf.setName("LnTF"); lNameTf.setInputVerifier(new MyVerifier(new JComponent[]{maleRb, femaleRb, okBtn})); panel.add(fNameLbl); panel.add(fNameTf); panel.add(fNamePicLbl); panel.add(lNameLbl); panel.add(lNameTf); panel.add(lNamePicLbl); panel.add(genderLbl); JPanel radioPanel = new JPanel(new FlowLayout(FlowLayout.LEFT)); radioPanel.add(maleRb); radioPanel.add(femaleRb); panel.add(radioPanel); panel.add(temp3); panel.add(okBtn); panel.add(cancelBtn); panel.add(tempBtn); panel.setLayout(new SpringLayout()); SpringUtilities.makeCompactGrid(panel, 4, 3, 50, 10, 80, 60); return panel; } public static void main(String[] args) { SwingUtilities.invokeLater(new Runnable() { @Override public void run() { new UserDialog(); } }); } public class MyVerifier extends InputVerifier { private JComponent[] component; public MyVerifier(JComponent[] components) { component = components; } @Override public boolean verify(JComponent input) { String name = input.getName(); if (name.equals("FnTF")) { String text = ((JTextField) input).getText().trim(); if (text.matches(".*\\d.*") || text.length() == 0) { //disable dependent components for (JComponent r : component) { r.setEnabled(false); } return false; } } else if (name.equals("LnTF")) { String text = ((JTextField) input).getText(); if (text.matches(".*\\d.*") || text.length() == 0) { //disable dependent components for (JComponent r : component) { r.setEnabled(false); } return false; } } //enable dependent components for (JComponent r : component) { r.setEnabled(true); } fNamePicLbl.setVisible(true); lNamePicLbl.setVisible(true); return true; } } } }

    Read the article

  • SQL - date variable isn't being parsed correctly?

    - by Bill Sambrone
    I am pulling a list of invoices filtered by a starting and ending date, and further filtered by type of invoice from a SQL table. When I specify a range of 2013-07-01 through 2013-09-30 I am receiving 2 invoices per company when I expect 3. When I use the built in select top 1000 query in SSMS and add my date filters, all the expected invoices appear. Here is my fancy query that I'm using that utilizing variables that are fed in: DECLARE @ReportStart datetime DECLARE @ReportStop datetime SET @ReportStart = '2013-07-01' SET @ReportStop = '2013-09-30' SELECT Entity_Company.CompanyName, Reporting_AgreementTypes.Description, Reporting_Invoices.InvoiceAmount, ISNULL(Reporting_ProductCost.ProductCost,0), (Reporting_Invoices.InvoiceAmount - ISNULL(Reporting_ProductCost.ProductCost,0)), (Reporting_AgreementTypes.Description + Entity_Company.CompanyName), Reporting_Invoices.InvoiceDate FROM Reporting_Invoices JOIN Entity_Company ON Entity_Company.ClientID = Reporting_Invoices.ClientID LEFT JOIN Reporting_ProductCost ON Reporting_ProductCost.InvoiceNumber =Reporting_Invoices.InvoiceNumber JOIN Reporting_AgreementTypes ON Reporting_AgreementTypes.AgreementTypeID = Reporting_Invoices.AgreementTypeID WHERE Reporting_Invoices.AgreementTypeID = (SELECT AgreementTypeID FROM Reporting_AgreementTypes WHERE Description = 'Resold Services') AND Reporting_Invoices.InvoiceDate >= @ReportStart AND Reporting_Invoices.InvoiceDate <= @ReportStop ORDER BY CompanyName,InvoiceDate The above only returns 2 invoices per company. When I run a much more basic query through SSMS I get 3 as expected, which looks like: SELECT TOP 1000 [InvoiceID] ,[AgreementID] ,[AgreementTypeID] ,[InvoiceDate] ,[Comment] ,[InvoiceAmount] ,[InvoiceNumber] ,[TicketID] ,Entity_Company.CompanyName FROM Reporting_Invoices JOIN Entity_Company ON Entity_Company.ClientID = Reporting_Invoices.ClientID WHERE Entity_Company.ClientID = '9' AND AgreementTypeID = (SELECT AgreementTypeID FROM Reporting_AgreementTypes WHERE Description = 'Resold Services') AND Reporting_Invoices.InvoiceDate >= '2013-07-01' AND Reporting_Invoices.InvoiceDate <= '2013-09-30' ORDER BY InvoiceDate DESC I've tried stripping down the 1st query to include only a client ID on the original invoice table, the invoice date, and nothing else. Still only get 2 invoices instead of the expected 3. I've also tried manually entering the dates instead of the @ variables, same result. I confirmed that InvoiceDate is defined as a datetime in the table. I've tried making all JOIN's a FULL JOIN to see if anything is hiding, but no change. Here is how I stripped down the original query to keep all other tables out of the mix and yet I'm still getting only 2 invoices per client ID instead of 3 (I manually entered the ID for the type filter): --DECLARE @ReportStart datetime --DECLARE @ReportStop datetime --SET @ReportStart = '2013-07-01' --SET @ReportStop = '2013-09-30' SELECT --Entity_Company.CompanyName, --Reporting_AgreementTypes.Description, Reporting_Invoices.ClientID, Reporting_Invoices.InvoiceAmount, --ISNULL(Reporting_ProductCost.ProductCost,0), --(Reporting_Invoices.InvoiceAmount - ISNULL(Reporting_ProductCost.ProductCost,0)), --(Reporting_AgreementTypes.Description + Entity_Company.CompanyName), Reporting_Invoices.InvoiceDate FROM Reporting_Invoices --JOIN Entity_Company ON Entity_Company.ClientID = Reporting_Invoices.ClientID --LEFT JOIN Reporting_ProductCost ON Reporting_ProductCost.InvoiceNumber = Reporting_Invoices.InvoiceNumber --JOIN Reporting_AgreementTypes ON Reporting_AgreementTypes.AgreementTypeID = Reporting_Invoices.AgreementTypeID WHERE Reporting_Invoices.AgreementTypeID = '22'-- (SELECT AgreementTypeID FROM Reporting_AgreementTypes WHERE Description = 'Resold Services') AND Reporting_Invoices.InvoiceDate >= '2013-07-01' AND Reporting_Invoices.InvoiceDate <= '2013-09-30' ORDER BY ClientID,InvoiceDate This strikes me as really weird as it is pretty much the same query as the SSMS generated one that returns correct results. What am I overlooking? UPDATE I've further refined my "test query" that is returning only 2 invoices per company to help troubleshoot this. Below is the query and a relevant subset of data for 1 company from the appropriate tables: SELECT Reporting_Invoices.ClientID, Reporting_AgreementTypes.Description, Reporting_Invoices.InvoiceAmount, Reporting_Invoices.InvoiceDate FROM Reporting_Invoices JOIN Reporting_AgreementTypes ON Reporting_AgreementTypes.AgreementTypeID = Reporting_Invoices.AgreementTypeID WHERE Reporting_Invoices.AgreementTypeID = (SELECT AgreementTypeID FROM Reporting_AgreementTypes WHERE Description = 'Resold Services') AND Reporting_Invoices.InvoiceDate >= '2013-07-01T00:00:00' AND Reporting_Invoices.InvoiceDate <= '2013-09-30T00:00:00' ORDER BY Reporting_Invoices.ClientID,InvoiceDate The above only returns 2 invoices. Here is the relevant table data: Relevant data from Reporting_AgreementTypes AgreementTypeID Description 22 Resold Services Relevant data from Reporting_Invoices InvoiceID ClientID AgreementID AgreementTypeID InvoiceDate 16111 9 757 22 2013-09-30 00:00:00.000 15790 9 757 22 2013-08-30 00:00:00.000 15517 9 757 22 2013-07-31 00:00:00.000 Actual results from my new modified query ClientID Description InvoiceAmount InvoiceDate 9 Resold Services 3513.79 7/31/13 00:00:00 9 Resold Services 3570.49 8/30/13 00:00:00

    Read the article

  • ActionBar SpinnerAdapter Large Branding followed by selection (spinner)

    - by SatanEnglish
    I'm trying to implement a spinner In the action bar that has brand Name above it. With the ActionBar setListNavigationCallbacks method if possible actionBar.setNavigationMode(ActionBar.NAVIGATION_MODE_LIST); actionBar.setListNavigationCallbacks(mSpinnerAdapter, null); Can anyone give me an Idea of how to do this? I would put some code here but I have no idea where to begin as I have not managed to find relevant information yet. Edit: Using V4.0

    Read the article

  • Use SQL Result to Query second time and grab more results via php

    - by maxwell
    I am grabbing a list of school names from a database. When the user clicks on the school name, i want the code to fetch 2-3 other attributes related to the school name that the user has clicked on. My code for the single school name list: $query = mysql_query("Select schoolname, product, username, password from credentials c join products p on p.productid = c.productid join schools s on s.schoolid = c.schoolid join icons i on i.productid = p.productid order by s.schoolname"); echo '<ul>'; while($row = mysql_fetch_array($query)) { echo "<li> <a href='#'>" . $row['schoolname'] . "</a> </li>"; } echo ''; Current Output: School A School A School B School B School B School C School C Expected Output: School name displayed only once (distinct won't work because each school name has 2-3 product credentials School A School B School C Ability for User to click on a school. then the school names underneath will move down (toggle effect) and user can see product, username and password displayed for the school clicked (for example: user clicked on School A) School A productname1, username, password productname2, username, password School B School C

    Read the article

  • java version of python-dateutil

    - by elhefe
    Python has a very handy package that can parse nearly any unambiguous date and provides helpful error messages on a parse failure, python-dateutil. Comparison to the SimpleDateFormat class is not favorable - AFAICT SimpleDateFormat can only handle one exact date format and the error messages have no granularity. I've looked through the Joda API but it appears Joda is the same way - only one explicit format can be parsed at a time. Is there any package or library that reproduces the python-dateutil behavior? Or am I missing something WRT Joda/SimpleDateFormat?

    Read the article

  • Run shell script using fabric and piping script text to shell's stdin

    - by Peter Lyons
    Is there a way to execute a multi-line shell script by piping it to the remote shell's standard input in fabric? Or must I always write it to the remote filesystem, then run it, then delete it? I like sending to stdin as it avoids the temporary file. If there's no fabric API (and it seems like there is not based on my research), presumably I can just use the ssh module directly. Basically I wish fabric.api.run was not limited to a 1-line command that gets passed to the shell as a command line argument, but instead would take a full multi-line script and write it to the remote shell's standard input.

    Read the article

  • throw new exception- C#

    - by Jalpesh P. Vadgama
    This post will be in response to my older post throw vs. throw(ex) best practice and difference- c# comment that I should include throw new exception. What’s wrong with throw new exception: Throw new exception is even worse, It will create a new exception and will erase all the earlier exception data. So it will erase stack trace also.Please go through following code. It’s same earlier post the only difference is throw new exception.   using System; namespace Oops { class Program { static void Main(string[] args) { try { DevideByZero(10); } catch (Exception exception) { throw new Exception (string.Format( "Brand new Exception-Old Message:{0}", exception.Message)); } } public static void DevideByZero(int i) { int j = 0; int k = i/j; Console.WriteLine(k); } } } Now once you run this example. You will get following output as expected. Hope you like it. Stay tuned for more..

    Read the article

  • ftp users configuration in OpenSuse 12

    - by chieroz
    I usually work with MacOSX servers but this time I need to set up a ftp service on a OpenSuse 12.2 server and I am a little lost. I am using the remote YAST2 tool via ssh. I created several users who can connect via ssh and/or ftp, so the basic setup is ok. But when connecting via ftp all my users don't have write permissions. The FTP directory for authenticated users is /srv/www/htdocs, which has permissions root:root. The OpenSuse manual say it's bad practice to change these permissions, but my normal users (even the ones in the sudoers list) cannot upload files. So I am stuck: as a workaround I use rsync, but from time to time I just need to establish a working ftp connection. What's the right approach for users permissions in this scenario? Thanks a lot.

    Read the article

  • How to know which revision or router I do have? [migrated]

    - by Rosamunda
    I´m trying to update my D-link Dir-600 router with the dd-wrt firmware. I´ve searched for it at the site and found that: Revision A1, B1 and B2 are supported, while C isn´t. Now my router has this information on the back: P/N IIR600GNA .... C1G H/W Ver: C1 F/W Ver: 3.01 So I guess the H/W Ver is the revision, and it´s C... so it´s a lost cause? Or maybe because it´s not just C but C1 I could do something with it? Thanks!

    Read the article

  • Watchguard firebox: public IP addresses behind firewall with as much usable IP addresses as possible

    - by martinezpt
    Our ISP assigned us 16 public IP addresses that we want to assign to hosts behind a Watchguard firebox x750e. The IP addresses are: x.x.x.176/28 of which x.x.x.177 is the gateway. The hosts will be running software that needs to be directly assigned the public IP address so 1:1 NAT is not an option. I found this document that gives examples on how to assign public IP addresses to hosts behind the firewall, using an optional interface: http://www.watchguard.com/help/configuration-examples/public_IP_behind_XTM_configuration_example_(en-US).pdf However, I can't implement scenario 1 as it won't allow me to use the same subnet on both interfaces. As for scenario 2, splitting the address range into 2 subnets will decrease the usable hosts on the optional interface to 5 (8 - network - broadcast - optional interface ip). I'm convinced that there must be a better way to address this problem and maximize the number of usable IP addresses but I'm not very familiar with this specific firewall. Are there any suggestions on how to keep the hosts behind the firewall with public IP addresses while maximizing the usable IP addresses? thanks

    Read the article

  • Bootstrapped Ubuntu 12.04 EC2 instance. Where to find log?

    - by nocode
    So I bootstrapped a shell script to install and run a bunch of tasks. Looks like the it ran for the most part, but I added one part and that was formatting an extra EBS volume. Pretty straightforward: mkfs.ext4 /dev/xvdf mkdir –m 000 /vol01 echo “/dev/xvdf /vol01 auto noatime 0 0” | sudo tee –a /etc/fstab sudo mount /vol01 I was able to install MongoDB, NGINX and Forever. I selected to use /dev/xdvf in the AWS console and see it. The 3rd line is not in fstab either. I've searched through various logs in /var/log/ but I don't really see much indicating the execution of the bootstrap. Logs that I see and looked through: auth.log boot.log dmesg dpkg.log syslog udev

    Read the article

  • nginx with fail2ban and mod_security

    - by Mahesh
    I forgot to update my fail2ban config for nginx. I just moved to nginx from apache. Today, I got a lot of cals from a single IP. IP tried to access login pages with post and get methods IP tried to use nginx as a proxy (GET http:/...) IP searched images, js, css folders IP tried to inject -d url_allow_fopen =1 and something similar. Most of the calls ended with 404. http { limit_req_zone $binary_remote_addr zone=app:10m rate=5r/s; ... server { ... location / { limit_req zone=app burst=50; } I got approximately 50 requests from that ip for a second. So i updated my nginx like the above. Will it avoid too many connections per second now? I have updated my fail2ban jail.local to support nginx. I am confused with the nginx-noscript.conf [Definition] failregex = ^<HOST> -.*GET.*(\.php|\.asp|\.exe|\.pl|\.cgi|\scgi) ignoreregex = I am serving php with nginx. I checked apache's noscript.conf and which has .php extension on it too. I tested this above settings before restarting fail2ban and got thousands of ips matched. I removed php and nothing matched. Do i need .php| in nginx-noscript.conf? Using mod_security and fail2ban together bring any problem? When i was searching today, i came to know mod_security is available for nginx too. So i am planning to use it too.

    Read the article

  • Google-Bot fell in love with my 404-page

    - by 32bitfloat
    Every day my access-log looks kind of this: 66.249.78.140 - - [21/Oct/2013:14:37:00 +0200] "GET /robots.txt HTTP/1.1" 200 112 "-" "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)" 66.249.78.140 - - [21/Oct/2013:14:37:01 +0200] "GET /robots.txt HTTP/1.1" 200 112 "-" "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)" 66.249.78.140 - - [21/Oct/2013:14:37:01 +0200] "GET /vuqffxiyupdh.html HTTP/1.1" 404 1189 "-" "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)" or this 66.249.78.140 - - [20/Oct/2013:09:25:29 +0200] "GET /robots.txt HTTP/1.1" 200 112 "-" "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)" 66.249.75.62 - - [20/Oct/2013:09:25:30 +0200] "GET /robots.txt HTTP/1.1" 200 112 "-" "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)" 66.249.78.140 - - [20/Oct/2013:09:25:30 +0200] "GET /zjtrtxnsh.html HTTP/1.1" 404 1186 "-" "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)" The bot calls the robots.txt twice and after that tries to access a file (zjtrtxnsh.html, vuqffxiyupdh.html, ...) which cannot exist and must return a 404 error. The same procedure every day, just the unexisting html-filename changes. The content of my robots.txt: User-agent: * Disallow: /backend Sitemap: http://mysitesname.de/sitemap.xml The sitemap.xml is readable and valid, so there seems to be no reason why the bot should want to force a 404-error. How should I interpret this behaviour? Does it point to a mistake I've done or should I ignore it?

    Read the article

  • Cannot establish XMPP server-to-server connection with gmail

    - by v_2e
    My jabber-server fails to connect to gmail.com giving the error: outgoing s2s stream myserver.com.ua-bot.talk.google.com closed: undefined-condition (myserver.com.ua is a Google Apps Domain with Talk service enabled.) I am using the Prosody XMPP server. It works just fine with other jabber-servers I tested so far (e.g. jabber.ru). However, when some of my clients tries to add a gmail contact to his contact-list, the subscription request lasts forever, and the Prosody gives the following sequence of messages in its log: Oct 21 22:57:16 s2sout95897f8 info Beginning new connection attempt to gmail.com ([173.194.70.125]:5269) Oct 21 22:57:16 s2sout95897f8 info sent dialback key on outgoing s2s stream Oct 21 22:57:16 s2sout95897f8 info Session closed by remote with error: undefined-condition (myserver.com.ua is a Google Apps Domain with Talk service enabled.) Oct 21 22:57:16 s2sout95897f8 info outgoing s2s stream myserver.com.ua->gmail.com closed: undefined-condition (myserver.com.ua is a Google Apps Domain with Talk service enabled.) Oct 21 22:57:16 s2sout95897f8 info sending error replies for 2 queued stanzas because of failed outgoing connection to gmail.com Here for the domain name of my server I use myserver.com.ua I found a similar problem described in this thread, but there is no detailed description of the solution there. As for the Google services, I did have a google account where I added the domain name under question to the Webmasters tools page. However, I deleted my account long ago, so now it is unclear, how any of the Google services can relate to my domain name. So my question is: What is the real cause of this problem (my jabber-server configuration or imaginary Google account or something else) and how can I make my Prosody server connect to gmail.com jabber service?

    Read the article

  • ITIL Incident Classification - Fault vs SR vs Technical Incident

    - by ExceptionLimeCat
    I am new to ITIL and Incident classifcations and I am trying learn more about them and understand how they could integrate in our organization. I have found it difficult to find a clear definition of Fault vs. Service Request vs. Technical incidents. I am basing my definitions on this article: http://www.itsmsolutions.com/newsletters/DITYvol6iss27.htm As I understand it: Service Request - Service provided by IT as part of regular administration of a system. Fault - An unexpected error in a system. Technical Incident - An interruption or potential interruption in IT service due to an expected incident caused by some IT policy.

    Read the article

  • CentOS - Disk Quota X% warning

    - by jfreak53
    I currently have disk quotas working perfectly for Hard Limit Quotas on a CentOS 5 box. Quotas are working fine, but I am looking for a way to alert users either in a Cron or Automatically as Quotas is already running, when they are within X% of their Hard Limit Quota? I would like this email to go out to an email address I configure somehow for each user. I've looked all over the place but can't find it. All I can find is warnquota which only works when a user goes over Quota. The problem is I use Hard Limits, so my users will never go over quota. It needs to warn them when they are within X% of their limits.

    Read the article

  • Is There any way to change Active Directory Users Database Source?

    - by Mehrdad Amini
    I need Active Directory Use My Own Custom Database (or shell or ...) for Authentication Users. Is there any extention or something like this to change User Passwords Database of active directory? I need this Because My Accounts Are In simple Database And I don't Want to Sync them periodically In Fact I can Not Change all My Applications to authenticate from Active Directory!Just I need Active Directory to Use My Database For Authentication.

    Read the article

  • Reverse Proxy issues IIS on Windows Server 2012

    - by ahwm
    I've tried searching, but nothing seems to be working. I have a feeling it might be due to our custom Rewrite module. Here is the excerpt from the web.config that sets it up: <modules runAllManagedModulesForAllRequests="true"> <add name="UrlRewriteModule" type="EShop.UrlRewriteModule"/> </modules> EShop.UrlRewriteModule is a custom class in App_Code which handles incoming requests. I have set up the rewrite rules but it doesn't seem to want to work. I'm inclined to think that our rewrite class is interfering earlier than the proxy rules and saying that the page doesn't exist. Here's what we're trying to accomplish: We are working on a new site for a client, but they have a forum that they're not likely to want to move. I set up a new subdomain to point to the new server while the site is being completed (before we go live) and want the reverse proxy to forward test.domain.com/forum to www.domain.com/forum. After the site goes live, we'll need to forward using an IP address instead. I've set up a reverse proxy successfully with nginx, but we didn't want to set up another server if we didn't need to. Ideas?

    Read the article

  • Input/output error reading USB backup drive on CentOS 6.4

    - by Kev
    I'm suddenly seeing some strange behaviour on our USB backup drive that doesn't make sense to me: (2013-10-21 14:58:23 [root@newdc /]$ cd /mnt/backup/ (2013-10-21 14:59:03 [root@newdc backup]$ ls -la ls: reading directory .: Input/output error total 0 (2013-10-21 14:59:05 [root@newdc backup]$ df -h /mnt/backup Filesystem Size Used Avail Use% Mounted on /dev/sda1 917G 843G 28G 97% /mnt/backup How is it possible for the OS to know how much is in use, but I can't ls any of it as root? Or more to the point, what problem does this indicate? /var/log/messages said this: Oct 21 14:57:54 g5 kernel: EXT4-fs error (device sda1): ext4_journal_start_sb: Detected aborted journal Oct 21 14:57:54 g5 kernel: EXT4-fs (sda1): Remounting filesystem read-only But...read-only is something different than 'throw an io error'... After unmounting to try fsck on it, I had someone on-site look at it, and the drive was not spun up, and had a slow-flashing light, which I believe means it was in a power-suspend mode. So I had them unplug and replug the USB cable, and now (before remounting) it says: fsck from util-linux-ng 2.17.2 e2fsck 1.41.12 (17-May-2010) /dev/sda1: clean, 2805106/61046784 files, 181934167/244182016 blocks I then mount it and now ls works and df reports: Filesystem Size Used Avail Use% Mounted on /dev/sda1 917G 680G 191G 79% /mnt/backup What would cause it to go into such a state without being asked to? Why all the weird behaviour, and now it appears to not be corrupt?

    Read the article

  • Httpd and LDAP Authentication not working for sub-pages

    - by DavisTasar
    I just recently installed a Nagios implementation, and I'm trying to get LDAP authentication working for httpd on Red Hat. (nagios.conf for Apache config below, sanitized of course) ScriptAlias /nagios/cgi-bin "/usr/local/nagios/sbin" <Directory "/usr/local/nagios/sbin"> #SSLRequireSSL Options ExecCGI AllowOverride none AuthType Basic AuthName "LDAP Authentication" AuthLDAPURL "ldap://my.domain.controller:389/OU=Users,DC=my,DC=domain,DC=controller?sAMAccountName?sub?(objectClass=user)" NONE AuthzLDAPAuthoritative off AuthLDAPBindDN "CN=NagiosAdmin,DC=my,DC=domain,DC=controller" AuthLDAPBindPassword "myPassword" require valid-user </Directory> Alias /nagios "/usr/local/nagios/share" <Directory /usr/local/nagios/share> #SSLRequireSSL Options None AllowOverride none AuthBasicProvider ldap AuthType Basic AuthName "LDAP Authentication" AuthzLDAPAuthoritative off AuthLDAPURL "ldap://my.domain.controller:389/OU=Users,DC=my,DC=domain,DC=controller?sAMAccountName?sub?(objectClass=user)" NONE AuthLDAPBindDN "CN=NagiosAdmin,DC=my,DC=domain,DC=controller" AuthLDAPBindPassword "myPassword" require valid-user </Directory> Now, the initial authentication works, so when you first hit the page you can log in just fine. However, when you go anywhere else, it prompts you for authentication, fails (asking for a re-prompt), and gives this error message: [Mon Oct 21 14:46:23 2013] [error] [client 172.28.9.30] access to /nagios/cgi-bin/statusmap.cgi failed, reason: verification of user id '<myuseraccount>' not configured, referer: http://<nagiosserver>/nagios/side.php I'm almost certain its a simple flag or option, but I just can't find it, and I don't have a lot of experience working with Apache. Any assistance or help would be greatly appreciated.

    Read the article

  • Amazon EC2 Nat Instance - goes out but not back in

    - by nocode
    I've followed Amazon's steps and list what I've done. I've created 6 subnets (4 private SN1: 10.50.1.0/24, SN2: 10.50.2.0/24, SN3: 10.50.3.0/24, SN4: 10.50.4.0/24) and 2 public (SN5: 10.50.101.0/24 and SN6: 10.50.102.0/24) -I have a Bastion host and a NAT instance on SN5 and assigned EIP's to both. I created a test instance on SN1. edit: -NAT instance has source/destination check disabled -On the NAT instance, I had enabled the following commands to be bootstrapped: echo 1 > /proc/sys/net/ipv4/ip_forward iptables -t nat -A POSTROUTING -s 10.0.0.0/16 -j MASQUERADE -In my VPC, the private subnets have their own route table and configured 0.0.0.0/0 to the NAT instance with 4 subnets being associated with the route table. I have a second route table for my public subnets and 0.0.0.0/16 is pointed towards the IGW (with the other 2 subnets associated with it). -For Security Groups, I have the NAT instance accepting all traffic on each of the 4 subnets and all OUTBOUND traffic is allowed. For my test server, I have allowed all outbound access and have allowed all traffic from the public subnet of the NAT host. I can ping internally with no issues. On my test instance, if I try to ping google.com, DNS resolves however I don't get a reply back. On my NAT instance, I run a tcpdump and can see the request being requested to google.com but it's not sending the reply back. My NAT host can ping and receive a reply from google. From the test host, when I ping the NAT instance, the tcpdump shows a request and receive. Is there something I'm missing? EDIT: I've figured it out - I had to save the iptable config and restart the service.

    Read the article

< Previous Page | 9 10 11 12 13 14 15 16 17 18  | Next Page >