Daily Archives

Articles indexed Wednesday January 5 2011

Page 33/35 | < Previous Page | 29 30 31 32 33 34 35  | Next Page >

  • SMB/CIFS connection, attempting to change the permissionswithin rhel5 to comply with the clients needs

    - by Skreemer
    I can get the mount to work and as written in /etc/fstab: //pcsprdvhost.prod.tsh.mis.mckesson.com/sftphome /sftphome2 cifs username=myuser,workgroup=domain,password=mypassword,noserverinfo,uid=tmadmin,gid=tibco,nounix,file_mode=0777,dir_mode=0777 0 2 this means that every directory under /sftphome2 looks like: drwxrwxrwx 1 tmadmin tibco 0 Jul 6 2010 D0000001 When I issue: chown -R D0000001:D0000001_admin D0000001 Nothing happens. When I pull the uid and gid specifications out I get the system owner/group of root:sys What I need to be able to do is change the sub-directories under /sftphome2 to whatever owner and group (and permissions) I desire versus the ones that are getting specified. How do I do this?

    Read the article

  • Configure postfix to filter email into hold queue

    - by Ian
    Hey, I would like postfix to send all emails received on SMTP off to an external process, which will decide whether to allow them through as normal, or whether to put them into the hold queue (or another quarantine area), where they have to wait for admin approval. I was thinking of doing this with an after-queue content filter, which uses pipe(8) to run a script on each message, and the script itself will spawn "postsuper -h " if it decides to put the message on hold. Then the admin can do postsuper -d or -r to delete or pass the message on as appropriate. So, my questions are - a) will this work, and b) is this the best way to do it? Would a milter or another type of content filter be a better approach?

    Read the article

  • MySQL keeps crashing due to bug

    - by mike
    So about a week ago, I finally figured out what was causing my server to continually crash. After reviewing my mysqld.log I keep seeing this same error, 101210 5:04:32 [Warning] option 'max_join_size': unsigned value 18446744073709551615 adjusted to 4294967295 Here is a link to the bug report, http://bugs.mysql.com/bug.php?id=35346 someone recommend that you set the max_join_size vaule in my.cnf to 4M, and I did. I assumed this fixed the issue, and it was working for about a week with no issues until today... I checked MySQL and the same error is now back, 101216 06:35:25 mysqld restarted 101216 6:38:15 [Warning] option 'max_join_size': unsigned value 18446744073709551615 adjusted to 4294967295 101216 6:38:15 [Warning] option 'max_join_size': unsigned value 18446744073709551615 adjusted to 4294967295 101216 06:40:42 mysqld ended Anyone know how I can really fix this issue? I can't keep having mysql crash like this. EDIT: I forgot to mention every time this happens I get an email from linode staying I have a high disk io rate Your Linode, has exceeded the notification threshold (1000) for disk io rate by averaging 2483.68 for the last 2 hours.

    Read the article

  • Installing Color-Theme with GNU Emacs 23.2 on OS X Snow Leopard

    - by idclark
    Hi all, I've just started using emacs a week ago and I've been unsuccessful in installing color-theme using GNU Emacs 23.2 on OS X. With Ubuntu the whole process took maybe a few minutes with the package manager, but I'm completely at a loss with OS X, what the heck is a "tarball"? I don't have any experience compiling source code. I know Carbon Emacs comes with color-theme packaged, what would i lose by reverting to Emacs 22? I'd prefer staying with GNU Emacs 23 across both systems. Any input is greatly appreciated!!

    Read the article

  • Wired USB mouse left button stops working

    - by InNeedOfHelp
    My wired USB mouse's left button stops working properly after being plugged into the computer for about five minutes. The mouse button will become sticky and not allow me to select things or the left button is completely unresponsive. The mouse driver is up to date. I am running Windows Vista Home Premium with the Service Pack 2 on a Sony Viao laptop (Model number (VGN-NW125J). If anybody knows how to fix this your help would be greatly appreciated.

    Read the article

  • Windows 7, how to get unlock (Press Ctrl+Alt+del) prompt on all monitors?

    - by Zugwalt
    I have a laptop that I keep shut in a docking station as I have two screens connected to the laptop and it cannot display to both of those AND its own screen. However, when my computer locks by itself (Not when I lock it using Ctrl+Alt+Del) the login prompt is ONLY on it screen (at least its there when I open it up) and my primary external monitor is off and my other one is all black. This means to log in I have to hit Ctrl+Alt+Del and blindly enter my password--which I don't mind too much, but would prefer if I could actually see the unlock/login prompt instead of typing on a black screen. Any way to have it show the login prompt on all monitors?

    Read the article

  • Nested Classes: A useful tool or an encapsulation violation?

    - by Bryan Harrington
    So I'm still on the fence as to whether or not I should be using these or not. I feel its an extreme violation of encapsulation, however I find that I am able to achieve some degree of encapsulation while gaining more flexibility in my code. Previous Java/Swing projects I had used nested classes to some degree, However now I have moved into other projects in C# and I am avoid their use. How do you feel about nested classes?

    Read the article

  • How should programmers handle email-username identity theft?

    - by Craige
    Background I recently signed up for an iTunes account, and found that somebody had fraudulently used MY email to register their iTunes account. Why Apple did not validate the email address, I will never know. Now I am told that I cannot use my email address to register a new iTunes account, as this email address is linked to an existing account. This got be thinking... Question How should we as developers handle email/identity theft? Obviously, we should verify that an email address belongs to the person it is said to belong to. Why Apple did not do this in my case, I have no idea. But lets pretend we use email address for login/account identification, and something slipped though the cracks (be it our end, or the users). How should we handle reports of fraudulent accounts?

    Read the article

  • The Art of Computer Programming - To read or not to read?

    - by Zannjaminderson
    There are lots of books about programming out there, and it seems Code Complete is pretty much at the top of most people's list of "must-read programming books", but what about The Art of Computer Programming by Donald Knuth? I'm a busy person, between work and a young family I don't have a ton of free time, so I have to be picky about how I use it. I'm wondering - has anybody here read 'TAOCP'? If so, is it worth making time to read or would some other book or more on-the-side programming like pet projects or contributing to open source be a better use of my time in terms of professional development? DISCLAIMER - For those of you who sport "Knuth is my homeboy" t-shirts, don't get me wrong - I want to read it, but I'm just wondering if it should be right at the top of my priority list or if something else should come first.

    Read the article

  • Software consultancy or in-house development?

    - by JefClaes
    What are the benefits and drawbacks of working as an in-house developer versus working as a consultant and vice versa? I am pretty sure both breeds can be found on these forums and I hope you are willing to share your experience. Edit: Let me clarify the question. I wonder what the experience is like being a developer. For example: being an in-house developer, you are able to learn from your mistakes. Being a consultant is often more challenging, because there is more variety in the problems you have to solve. PS: Although I realise that this is a subjective question, I don't necessarily see it as one of those bad-subjective questions.

    Read the article

  • How Do I Do Alpha Transparency Properly In XNA 4.0?

    - by Soshimo
    Okay, I've read several articles, tutorials, and questions regarding this. Most point to the same technique which doesn't solve my problem. I need the ability to create semi-transparent sprites (texture2D's really) and have them overlay another sprite. I can achieve that somewhat with the code samples I've found but I'm not satisfied with the results and I know there is a way to do this. In mobile programming (BREW) we did it old school and actually checked each pixel for transparency before rendering. In this case it seems to render the sprite below it blended with the alpha above it. This may be an artifact of how I'm rendering the texture but, as I said before, all examples point to this one technique. Before I go any further I'll go ahead and paste my example code. public void Draw(SpriteBatch batch, Camera camera, float alpha) { int tileMapWidth = Width; int tileMapHeight = Height; batch.Begin(SpriteSortMode.Texture, BlendState.AlphaBlend, SamplerState.PointWrap, DepthStencilState.Default, RasterizerState.CullNone, null, camera.TransformMatrix); for (int x = 0; x < tileMapWidth; x++) { for (int y = 0; y < tileMapHeight; y++) { int tileIndex = _map[y, x]; if (tileIndex != -1) { Texture2D texture = _tileTextures[tileIndex]; batch.Draw( texture, new Rectangle( (x * Engine.TileWidth), (y * Engine.TileHeight), Engine.TileWidth, Engine.TileHeight), new Color(new Vector4(1f, 1f, 1f, alpha ))); } } } batch.End(); } As you can see, in this code I'm using the overloaded SpriteBatch.Begin method which takes, among other things, a blend state. I'm almost positive that's my problem. I don't want to BLEND the sprites, I want them to be transparent when alpha is 0. In this example I can set alpha to 0 but it still renders both tiles, with the lower z ordered sprite showing through, discolored because of the blending. This is not a desired effect, I want the higher z-ordered sprite to fade out and not effect the color beneath it in such a manner. I might be way off here as I'm fairly new to XNA development so feel free to steer me in the correct direction in the event I'm going down the wrong rabbit hole. TIA

    Read the article

  • wpf datagrid on click event

    - by gencay
    I use datagrid table on my project. One of the column of the datagrid is the path of the document according to my project. I would like to do that: When the user clicks the path cell/hyperlink cell, Program will get the path, Program will open another tab. I couldn't see the onclick event for the column, how can i do this? And also how can I switch the tabitems on the same wpf Window? Hyper link column is that: < toolkit:DataGridHyperlinkColumn Header="Path" Binding="{Binding path}" IsReadOnly="True" TargetName="{Binding Path=path}"

    Read the article

  • Is CakePhp 'standards compliant' when generating HTML, Forms, etc?

    - by dtj
    So I've been reading a lot of "Designing with Web Standards" and really enjoying it. I'm a big CakePhp user, and as I look at the source for various form elements that Cake creates with its FormHelper, I see all sorts of extraneous In the book, he promotes semantic HTML, and writing your markup as simple / generic as possible. So my question is, am I better writing my own HTML in these situations? I really want to work in compliance with XHTML and CSS standards, and it seems I'd spend just as much time (if not more) cleaning up Cakes HTML, when I could just write my own thoughts? p.s. Here's an example in an out of the box form that CakePhp generates using the FormHelper <form id="CompanyAddForm" method="post" action="/omni_cake/companies/add" accept-charset="utf-8"><div style="display:none;"><input type="hidden" name="_method" value="POST" /></div> <div class="input text required"><label for="CompanyName">Name</label><input name="data[Company][name]" type="text" maxlength="50" id="CompanyName" /></div> <div class="input text required"><label for="CompanyWebsite">Website</label><input name="data[Company][website]" type="text" maxlength="50" id="CompanyWebsite" /></div> <div class="input textarea"><label for="CompanyNotes">Notes</label><textarea name="data[Company][notes]" cols="30" rows="6" id="CompanyNotes" ></textarea></div> <div class="submit"><input type="submit" value="Submit" /></div></form>

    Read the article

  • The HTTP verb POST used to access path '[my path]' is not allowed.

    - by Jed
    I am receiving an error that states: "The HTTP verb POST used to access path '[my path]' is not allowed.". The error is being caused by the fact that I am implementing an HTML form element that uses the POST method and does not explicitly define an .aspx page in its ACTION parameter. For example: <form action="" method="post"> <input type="submit" /> </form> The HTML above is on a file at "/foo/default.aspx". Now, if the user points the URL to the root directory "foo" without specifying the aspx file (i.e. "http://localhost/foo") and then submits the form, the error "The HTTP verb POST used to access path '/foo' is not allowed." will be thrown. However, if the user goes to "http://localhost/foo/default.aspx" and then submits the form, all goes well (even if the ACTION parameter is left empty). Note: If I explicitly add the name of the .aspx (default.aspx) page to the ACTION parameter, no errors are thrown. So the example below works fine regardless if the user defines the name of the file in the URL or not. <form action="default.aspx" method="post"> <input type="submit" /> </form> I was curious as to why the error was being thrown, so I read a Microsoft KB that states This problem occurs because a client makes an HTTP request by sending the POST method to a static HTML page. Static HTML pages do not support the POST method. I suppose the core of the explanation makes sense, however in my case, my form is not being sent to a static html page - it's being sent to the same page that the html form lives on (default.aspx)... this is implicit to an ACTION param that is left empty. Is it possible to configure IIS (or otherwise) that will allow us to do form POSTing and keep the ACTION param empty?

    Read the article

  • Do I need to write a trigger for such a simple constraint?

    - by Paul Hanbury
    I really had a hard time knowing what words to put into the title of my question, as I am not especially sure if there is a database pattern related to my problem. I will try to simplify matters as much as possible to get directly to the heart of the issue. Suppose I have some tables. The first one is a list of widget types: create table widget_types ( widget_type_id number(7,0) primary key, description varchar2(50) ); The next one contains icons: create table icons ( icon_id number(7,0) primary key, picture blob ); Even though the users get to select their preferred widget, there is a predefined subset of widgets that they can choose from for each widget type. create table icon_associations ( widget_type_id number(7,0) references widget_types, icon_id number(7,0) references icons, primary key (widget_type_id, icon_id) ); create table icon_prefs ( user_id number(7,0) references users, widget_type_id number(7,0), icon_id number(7,0), primary key (user_id, widget_type_id), foreign key (widget_type_id, icon_id) references icon_associations ); Pretty simple so far. Let us now assume that if we are displaying an icon to a user who has not set up his preferences, we choose one of the appropriate images associated with the current widget. I'd like to specify the preferred icon to display in such a case, and here's where I run into my problem: alter table icon_associations add ( is_preferred char(1) check( is_preferred in ('y','n') ) ) ; I do not see how I can enforce that for each widget_type there is one, and only one, row having is_preferred set to 'y'. I know that in MySQL, I am able to write a subquery in my check constraint to quickly resolve this issue. This is not possible with Oracle. Is my mistake that this column has no business being in the icon_associations table? If not where should it go? Is this a case where, in Oracle, the constraint can only be handled with a trigger? I ask only because I'd like to go the constraint route if at all possible. Thanks so much for your help, Paul

    Read the article

  • Accessing vars from another clojure namespace?

    - by erikcw
    In my main namespace, I have a top level var named "settings" which is initialized as an empty {}. My -main fn sets the contents of settings using def and conj based on some command line args (different database hosts for production/development, etc). I'm trying to access the contents of this map from another namespace to pull out some of the settings. When I try to compile with lein into an uberjar, I get a traceback saying "No such var: lb/settings". What am I missing? Is there a more idiomatic way to handle app wide settings such as these? Is it safe to use "def" inside of -main like I am, or should I be use an atom or ref to make this threadsafe? Thanks! (ns main (:use ...) (:gen-class)) (def settings {}) (defn -main [& args] (with-command-line-args... ;set devel? based on args (if (true? devel?) (def settings (conj settings {:mongodb {:host "127.0.0.1"} :memcached {:host "127.0.0.1"}})) (def settings (conj settings {:mongodb {:host "PRODUCTION_IP"} :memcached {:host "PRODUCTION_IP"}}))) ;file2.clj (ns some-other-namespace (:require [main :as lb] ...) ;configure MongoDB (congo/mongo! :db "dbname" :host (:host (mongodb lb/settings)))) ...

    Read the article

  • SoapUI JMS Connections

    - by Damo
    I am using SoapUI to do performance testing of some services over JMS using WebSphere MQ as the JMS Provider. SoapUI uses HermesJMS to provide the JMS Connection details for the JMS Endpoint. I've noticed that when I call a request from SoapUI the JMS Connection is never closed. This results in hundreds of SYSTEM.DEF.SVRCONN channel connections. It seems to be specific to SoapUI as HermeJMS doesn't exhibit this behaviour. Has anyone else seen this?

    Read the article

  • Sending an SMS in Android

    - by D4N14L
    Hey, I have been making an Android app which needs to send a text message. Here is the current code I have: public class getMessage extends Service { @Override public IBinder onBind(Intent intent) { return null; } @Override public void onStart(Intent intent, int startId) { super.onStart(intent, startId); client Phone = new client(); String[] msg = Phone.getMsg(user[0],user[1]); PendingIntent pi = PendingIntent.getActivity(this, 0, new Intent(this, getMessage.class), 0); SmsManager man = SmsManager.getDefault(); Log.e("GOT MESSAGE", msg[0]+ " : " +msg[1]); man.sendTextMessage(msg[0], null, msg[1], pi, null); Log.e("Message", "Sent the message?"); } Now, for some reason, the text message will not send using this code, and I'm not sure why. I was hoping that someone here could help me out in finding why this message won't send. No error is raised, nothing appears in the log (except for the log messages that I make myself in the code). Also, the manifest does have the correct tags. Suggestions?

    Read the article

  • Unit testing of static library that involves NSDocumentDirectory and other iOS App specific calls.

    - by Shiun
    Hi, I'm attempting to run unit tests for a static library that attempts to create/write/read a file in the document directory. Since this is a static library and not an application for the iOS, attempts to reference the NSDocumentDirectory is returning me directory for the form "/Users//Library/Application Support/iPhone Simulator/Documents" This directory does not exist. When attempting to access a directory from an actual application, the NSDocumentDirectory returns something of the form: "/Users//Library/Application Support/iPhone Simulator/4.2/FEDBEF5F-1326-4383-A087-CDA1B865E61A/Documents" (Please note the simulator version as well as application ID as part of the path) How can I overcome this shortcoming in the unit test framework for static libraries that implement tests that require iOS app specific calls? Thanks in advance.

    Read the article

  • How can I find the boundaries of a subset of a sorted list?

    - by Alex
    I have the following dilemma: I have a list of strings, and I want to find the set of string which start with a certain prefix. The list is sorted, so the naive solution is this: Perform binary search on the prefixes of the set, and when you find an element that starts with the prefix, traverse up linearly until you hit the top of the subset. This runs in linear time, however, and I was wondering if anyone can suggest a more efficient way to do it.

    Read the article

  • Need an end of lexical scope action which can die normally

    - by Schwern
    I need the ability to add actions to the end of a lexical block where the action might die. And I need the exception to be thrown normally and be able to be caught normally. Unfortunately, Perl special cases exceptions during DESTROY both by adding "(in cleanup)" to the message and making them untrappable. For example: { package Guard; use strict; use warnings; sub new { my $class = shift; my $code = shift; return bless $code, $class; } sub DESTROY { my $self = shift; $self->(); } } use Test::More tests => 2; my $guard_triggered = 0; ok !eval { my $guard = Guard->new( #line 24 sub { $guard_triggered++; die "En guarde!" } ); 1; }, "the guard died"; is $@, "En guarde! at $@ line 24\n", "with the right error message"; is $guard_triggered, 1, "the guard worked"; I want that to pass. Currently the exception is totally swallowed by the eval. This is for Test::Builder2, so I cannot use anything but pure Perl. The underlying issue is I have code like this: { $self->setup; $user_code->(); $self->cleanup; } That cleanup must happen even if the $user_code dies, else $self gets into a weird state. So I did this: { $self->setup; my $guard = Guard->new(sub { $self->cleanup }); $user_code->(); } The complexity comes because the cleanup runs arbitrary user code and it is a use case where that code will die. I expect that exception to be trappable and unaltered by the guard. I'm avoiding wrapping everything in eval blocks because of the way that alters the stack.

    Read the article

  • What's the best way to "shuffle" a table of database records?

    - by Darth
    Say that I have a table with a bunch of records, which I want to randomly present to users. I also want users to be able to paginate back and forth, so I have to perserve some sort of order, at least for a while. The application is basically only AJAX and it uses cache for already visited pages, so even if I always served random results, when the user tries to go back, he will get the previous page, because it will load from the local cache. The problem is, that if I return only random results, there might be some duplicates. Each page contains 6 results, so to prevent this, I'd have to do something like WHERE id NOT IN (1,2,3,4 ...) where I'd put all the previously loaded IDs. Huge downside of that solution is that it won't be possible to cache anything on the server side, as every user will request different data. Alternate solution might be to create another column for ordering the records, and shuffle it every insert time unit here. The problem here is, I'd need to set random number out of a sequence to every record in the table, which would take as many queries as there are records. I'm using Rails and MySQL if that's of any relevance.

    Read the article

  • Any way to make a generic List where I can add a type AND a subtype?

    - by user383178
    I understand why I cannot do the following: private class Parent { }; private class Child extends Parent { }; private class GrandChild extends Child { }; public void wontCompile(List<? extends Parent> genericList, Child itemToAdd) { genericList.add(itemToAdd); } My question is there ANY practical way to have a typesafe List where you can call add(E) where E is known to be only a Parent or a Child? I vaguely remember some use of the "|" operator as used for wildcard bounds, but I cannot find it in the spec... Thanks!

    Read the article

  • How do you prevent Git from printing 'remote:' on each line of the output of a post-recieve hook?

    - by Matt Hodan
    I recently configured an EC2 instance with a Git deployment workflow that resembles Heroku, but I can't seem to figure out how Heroku prevents the Git post-receive hook from outputting 'remote:' on each line. Consider the following two examples (one from my EC2 project and one from a Heroku project): My EC2 project: git push prod master Counting objects: 9, done. Delta compression using up to 2 threads. Compressing objects: 100% (5/5), done. Writing objects: 100% (5/5), 456 bytes, done. Total 5 (delta 3), reused 0 (delta 0) remote: remote: Receiving push remote: Deploying updated files (by resetting HEAD) remote: HEAD is now at bf17da8 test commit remote: Running bundler to install gem dependencies remote: Fetching source index for http://rubygems.org/ remote: Installing rake (0.8.7) remote: Installing abstract (1.0.0) ... remote: Installing railties (3.0.0) remote: Installing rails (3.0.0) remote: Your bundle is complete! It was installed into ./.bundle/gems remote: Launching (by restarting Passenger)... done remote: To ssh://[email protected]/~/apps/app_name e8bd06f..bf17da8 master -> master Heroku: $> git push heroku master Counting objects: 179, done. Delta compression using up to 2 threads. Compressing objects: 100% (89/89), done. Writing objects: 100% (105/105), 42.70 KiB, done. Total 105 (delta 53), reused 0 (delta 0) -----> Heroku receiving push -----> Rails app detected -----> Gemfile detected, running Bundler version 1.0.3 Unresolved dependencies detected; Installing... Using --without development:test Fetching source index for http://rubygems.org/ Installing rake (0.8.7) Installing abstract (1.0.0) ... Installing railties (3.0.0) Installing rails (3.0.0) Your bundle is complete! It was installed into ./.bundle/gems Compiled slug size is 4.8MB -----> Launching... done http://your_app_name.heroku.com deployed to Heroku To [email protected]:your_app_name.git 3bf6e8d..642f01a master -> master

    Read the article

  • How does cross domain file (receiver) work?

    - by seatoskyhk
    So, how does it work? How come having a receiver.html can allow cross domain communication? I... just... don't understand. For example, (using Heyzap as example) <script type="text/javascript" src="http://tools.heyzap.com/external/tools/v4.js"></script> <script type="text/javascript"> HeyzapTools.load({ game_key: "your-game-key-here", hz_receiver_url: "http://example.com/hz_receiver.html" }); </script> and the hz_receiver.html has this content: <html> <body> <script src="/external/tools/hz_receiver.js" type="text/javascript"></script> </body> </html> so, why it will allow cross domain?

    Read the article

< Previous Page | 29 30 31 32 33 34 35  | Next Page >